gautammalkani
Technical User
Hi All
How do I link an access table to Excel. I want the user to input a userid and password (that is currently hardcoded) and compare it to the ids and passwords in MS Access before allowing the user to submit the data. Any suggestions will be much appreciated. Thanks for your help.
Gautam
PS. As shown below, this is the username & password code that just verifies it for one case.
Private Sub submitbutton_Click()
' When the userlogs on, if is username and password are correct
' a confirmation message is displayed otherwise an
' error message pops up
' in both events, the usernames and passwords are
' reset so that the user must log on each time
' in order to send information to P&G
UserForm1.Hide
If (Username.Text = "malkani.gr@pg.com") And (password.Text = "portal123") Then
UserForm1.Hide
confirmation = MsgBox("Your data is now being uploaded", vbOKOnly, "Confirmation", "DEMO.HLP", 1000)
Username.Text = ""
password.Text = ""
Pub
Else
error_message = MsgBox("LDAP Login Failure!!!!", vbOKOnly, "No such userid for this password", "DEMO.HLP", 1000)
Username.Text = ""
password.Text = ""
UserForm1.Show
End If
End Sub
How do I link an access table to Excel. I want the user to input a userid and password (that is currently hardcoded) and compare it to the ids and passwords in MS Access before allowing the user to submit the data. Any suggestions will be much appreciated. Thanks for your help.
Gautam
PS. As shown below, this is the username & password code that just verifies it for one case.
Private Sub submitbutton_Click()
' When the userlogs on, if is username and password are correct
' a confirmation message is displayed otherwise an
' error message pops up
' in both events, the usernames and passwords are
' reset so that the user must log on each time
' in order to send information to P&G
UserForm1.Hide
If (Username.Text = "malkani.gr@pg.com") And (password.Text = "portal123") Then
UserForm1.Hide
confirmation = MsgBox("Your data is now being uploaded", vbOKOnly, "Confirmation", "DEMO.HLP", 1000)
Username.Text = ""
password.Text = ""
Pub
Else
error_message = MsgBox("LDAP Login Failure!!!!", vbOKOnly, "No such userid for this password", "DEMO.HLP", 1000)
Username.Text = ""
password.Text = ""
UserForm1.Show
End If
End Sub