erick-flores said:
Hello
I have 2 groups: Admins, EnterData
I want to display some objects in my forms when the EnterData group
users are logon and display all the objects when the Admins are logon
on.
You don't want to give users access to the database window at all. You
should create a 'menu' type form that allows users to open the various
forms/reports that they need to use. This form would just have command
buttons on it to open the various forms, etc. You can hide buttons
depending on the group the user is a member of. There is code in the
security FAQ you can use to determine if a user is a member of a group. In
the open event of this menu form you'd use...
If faq_IsUserInGroup("EnterData",CurrentUser) then
Me.cmdWhatever.Visible = False
Me.cmdSomething.Visible = False
Else
Me.cmdWhatever.Visible = True
Me.cmdSomething.Visible = True
End If
Create custom menus/toolbars for use throughout your application.
Use the features in Tools, Startup to
set the startup form (your menu form)
set your default menu (the custom one you made)
disable all the checkboxes about allowing built in menus, toolbars,
changes etc.
hide the db window (ensure the custom menu you create does not
include the Windows, Unhide item)
uncheck the allow special keys (this will disable the F11 key, among
others)
If you need to bypass these startup features, you can hold the shift key
down while you open the db. If you feel that your users may use this to
bypass your settings, you can disable the shift key bypass - there's an
example in help for doing this(look for AllowBypassKey) or at
http://www.mvps.org/access/modules/mdl0011.htm
and
http://www.mvps.org/access/general/gen0040.htm
You can also create a MDE from your database, which will prevent changes to
forms, reports and modules (If you do this, be certain to keep your original
mdb in case you need to make changes).