jcu123
03-28-2007, 11:57 AM
I have a database that uses Login_id and password to control access and what people see. I use Login_id as stLinkCriteria to open subforms. I have a reports subform that I want only admins to have access to. I have a Security_level field to distinguish Admins (=1) from regular users (=2) and think I should be able to use that in conjunction with the Login_id to do that but I cannot get the syntax right. Here is my current code:
stDocName = "frm_admin_rpts"
stLinkCriteria = "[Login_ID]=" & "'" & Me![Login_ID] & "'"
DoCmd.OpenForm stDocName, , , stLinkCriteria
How do I add "Security_Level=1" to that?
Thanks for any advice!
stDocName = "frm_admin_rpts"
stLinkCriteria = "[Login_ID]=" & "'" & Me![Login_ID] & "'"
DoCmd.OpenForm stDocName, , , stLinkCriteria
How do I add "Security_Level=1" to that?
Thanks for any advice!