arage
01-02-2001, 11:25 AM
Refrencing table records
Hi,
The following code is my attempt at accessing a table called password & checking fields in it called region code & password against the text controls on my form. Its not working though. How can I match my unbound fields with a record in a table? I get errors that field tables (!) is not accessible by axs97 so there is a problem b/c that’s the table name not field name.
Thanks!
If Me!txtRegionCode = [tables]![passwords]!RegionCode Then
If Me!txtPassword = [tables]![passwords]!Password Then
stDocName = "Menu"
DoCmd.OpenForm stDocName, , , stLinkCriteria
End If
MsgBox "You have not been authorized to use this program.", vbExclamation, "RE-LOGIN"
Exit Sub
End If
Hi,
The following code is my attempt at accessing a table called password & checking fields in it called region code & password against the text controls on my form. Its not working though. How can I match my unbound fields with a record in a table? I get errors that field tables (!) is not accessible by axs97 so there is a problem b/c that’s the table name not field name.
Thanks!
If Me!txtRegionCode = [tables]![passwords]!RegionCode Then
If Me!txtPassword = [tables]![passwords]!Password Then
stDocName = "Menu"
DoCmd.OpenForm stDocName, , , stLinkCriteria
End If
MsgBox "You have not been authorized to use this program.", vbExclamation, "RE-LOGIN"
Exit Sub
End If