Lock users from viewing tables (1 Viewer)

Jennesa

Registered User.
Local time
Yesterday, 21:04
Joined
Jun 24, 2016
Messages
23
I have created a login form and set users with access Levels, ex. 1 - Administrator, 2 - Editor, 3 - Reader. What I am trying to do is see if there is a way that if a user with the access levels 2 or 3 logs in to that database certain tables/information should be inaccessible to them.
 

Cronk

Registered User.
Local time
Today, 11:04
Joined
Jul 4, 2013
Messages
2,771
Depends on how Access savvy your users are.

For most of my applications, I just hide the navigator window and apply access levels to which forms can be opened or editted.

Otherwise you can disable special keys such as F11 which displays a hidden navigator window but make sure you set up (and test on a copy) that you have a back door to enable you to get to the tables.
 

Jennesa

Registered User.
Local time
Yesterday, 21:04
Joined
Jun 24, 2016
Messages
23
I would but the problem is actually that my users are not savvy at all. The owner would still need to see the navigation pane but our office assistants wouldn't. If there is a way that I can put in a line of code in the login so that when the office assistants log in they cannot open tables with sensitive information. Does that make sense? I'm pretty savvy with access but not with coding!
 

Cronk

Registered User.
Local time
Today, 11:04
Joined
Jul 4, 2013
Messages
2,771
As I wrote before, don't show the Navigation panel. All data input should be via forms. You can develop your own customized ribbon to open particular forms and reports (requires some coding) or use the inbuilt switchboard manager (no code but search for tutorials on how to use).

You will have to code a test for access level. Something like the following in the form open event

(a) to stop access to a form
if userlevel > 1 then
'--Not admin
Cancel = true '--Closes form
endif

(b) to have read only
if userlevel <3 then
'--Admin, or edit user
me.allowedits = true
me.allowdeletions = true
me.allowadditions = true
else
me.allowedits = false
me.allowdeletions = false
me.allowadditions = false
endif
 

Users who are viewing this thread

Top Bottom