hi
need your help please
i am trying to create a password for entering my form.
what i did:
i open the form in design view - EVENT - ON OPEN -... i wrote this code (bellow):
Dim password As String
password = InputBox("and the password is.....")
If password = "1Q1Q" Then
MsgBox "Welcome Engineer"
Else
MsgBox "check the CapsLK my friend..."
DoCmd.Close
End If
than when i closed the form and try to enter the form this error appear:
The expression On Open you entered as the event property setting produced the following error: a problem occurred while microsoft access was communicating with the OLE server or Activex control
This error occurs when an event has failed to run because the location of the logic for the event cannot be evaluated. For example, if the OnOpen property of a form is set to =[Field], this error occurs because a macro or event name is expected to run when the event occurs.
thanks