[英]MS access password protect for other users
1.I have created a MS access db, where list of values are present in single excel column. 1.我创建了一个MS Access数据库,其中的值列表在单个Excel列中。 Then i have created a 2 form first is background and 2nd is sku search.As in the screenshot. 然后我创建了一个2表单,第一个是背景,第二个是sku search.As在屏幕截图中。 The use of the serach text is to searcha data from the list and gives result if present. Serach文本的用途是从列表中搜索数据并给出结果(如果存在)。 I want to share it to different user.But i dont want them to edit it. 我想与其他用户共享。但是我不希望他们对其进行编辑。 Now if i select "Alt+f11", then Design mode and it allows to edit. 现在,如果我选择“ Alt + f11”,则在“设计”模式下可以进行编辑。 I want the different user should not see the excel data. 我希望其他用户不应该看到excel数据。
If you don't want them to edit the data, then make textbox.enabled = False (this is on the Data tab of the Property sheet). 如果您不希望他们编辑数据,则使textbox.enabled = False(在“属性”表的“数据”选项卡上)。
If you want to make it so the user can't edit the form, you can trap for f11 in the On Key Down event of the form itself. 如果要创建它以便用户无法编辑表单,则可以在表单本身的On Key Down事件中捕获f11。 It's been a while since I've done that, but I believe this will work: 自从我这样做已经有一段时间了,但是我相信这会起作用:
Private Sub Form_KeyDown(KeyCode As Integer, Shift As Integer)
Select Case KeyCode
Case vbKeyF11
KeyCode = 0
MsgBox "Access not allowed"
Case Else
End Select
End Sub
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.