有关ADP禁止SHIFT键的方法
时 间:2003-12-14 09:30:54
作 者:tmtony ID:186 城市:中山
摘 要:有关ADP禁止SHIFT键的方法
正 文:
Function DisableBypassADP(blnYesNo As Boolean)
CurrentProject.Properties.Add "AllowByPassKey", blnYesNo
End Function
然后在启动时调用 DisableBypassADP(false)
更详细的做法:
Function SetMyProperty(MyPropName As String, MyPropvalue As Variant) As Boolean
On Error GoTo SetMyProperty_In_Err
Dim Ix As Integer
With CurrentProject.Properties
If fn_PropertyExist(MyPropName) Then 'check if it already exists
For Ix = 0 To .Count - 1
If .Item(Ix).Name = MyPropName Then
.Item(Ix).value = MyPropvalue
End If
Next Ix
Else
.Add MyPropName, MyPropvalue
End If
End With
SetMyProperty = True
SetMyProperty_Exit:
Exit Function
SetMyProperty_In_Err:
MsgBox "设置属性出错:", Err, Error$
SetMyProperty = False
Resume SetMyProperty_Exit
End Function
'--------检查属性是否存在---
Private Function fn_PropertyExist(MyPropName As String) As Boolean
fn_PropertyExist = False
Dim Ix As Integer
With CurrentProject.Properties
For Ix = 0 To .Count - 1
If .Item(Ix).Name = MyPropName Then
fn_PropertyExist = True
Exit For
End If
Next Ix
End With
End Function
Public Function setByPass()
SetMyProperty "AllowBypassKey", True
End Function
Access软件网官方交流QQ群 (群号:54525238) Access源码网店
常见问答:
技术分类:
源码示例
- 【源码QQ群号19834647...(12.17)
- Access自定义消息盒Msg...(04.28)
- Access怎么按每个月份里面...(03.09)
- Access怎么按季度来统计人...(02.26)
- Access怎么按年龄段来统计...(01.26)
- 【Access高效办公】上一年...(12.29)
- 用Access连续窗体制作的树...(11.03)
- 【Access高效办公】上一年...(10.30)
- Access制作的RGB转CM...(09.22)
- Access制作的RGB调色板...(09.15)
学习心得
最新文章
- 用SQL代码更改SQL Serve...(05.29)
- Access快速开发平台--图片附...(05.29)
- 如何用VBA检查表有没有设置主键(05.28)
- 用VBA来指定图表中横坐标/纵坐标...(05.25)
- 还在凭感觉建表?Access建表思...(05.25)
- ACCESS视频手机上看瞎眼?用电...(05.24)
- 用SSMS将ACCESS中的表导入...(05.21)
- 自动编号用不好,系统迟早要乱!Ac...(05.21)
- Access原生开发VS快速开发:...(05.20)
- 不用记密码!用Access打造私人...(05.18)


.gif)
