ms access password

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Is there anyway of password protecting just one form in a database???
 
Sure--there are a number of possibilities. For example, you could disable the visibility of all the form objects by default. Then capture user input by using an inputbox and perform a comparison against a hard coded password variable using the form's OnOpen event. if the user enters the correct password, the script can change the form objects and enable their visibility. Here's a possibility:

Dim vPassword As String
Dim vInput As String

vPassword = 123ABC
vInput = Inputbox("Enter Password: ")

If vPassword = vInput Then
Me.tboTextA.Visible = True
Me.tboTestB.Visible = True
'ADD MORE HERE
Else
MsgBox "Password Incorrect"
DoCmd.Close 'CLOSES FORM
End If

So to answer your question, yes--it is possible.

Best regards,

Todd
Is there anyway of password protecting just one form in a database???
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

Windows 10 W10 password prob. 2
Are password protected WiFi networks secure? 3
Excel Protection 2
Wifi Network Issue 0
Excel Excel macro and passwords 3
Link to Database - Password 1
Using Access Security 9
The account password for MS Office Outlook 2010 1

Back
Top