Menu

  • Thread starter Thread starter Martin
  • Start date Start date
M

Martin

I want a specific menu to launch ONLY when Admin Logs
in. I want everyone else to get the default menu, which
I have stripped down. How do I do this?
 
Hi Martin

Put the following in the code that executes when your database opens:

If CurrentUser = "Admin" then
Application.MenuBar = "Name of Admin Menu"
Else
Application.MenuBar = "Name of User Menu"
End If

****However****
If you have secured your database correctly, you should not be logging in as
Admin, because Admin should have no permissions to any objects. Admin is
the same in every workgroup file, so a user needs only to open your database
with a copy of the default SYSTEM.MDW and s/he will have the same
permissions without username/password that you have logging in as Admin.

You should create a new user in the Admins group, then while logged in as
that user, create a new database, then import everything from the old
database (so that Admin no longer owns the database and its objects), and
finally, remove Admin from the Admins group, and remove all permissions for
all objects from Admin and Admins.
 
Wouldn't that person need to know the Admin Password in
order to change the workgroup file? If they open the
database with the workgroup not available, does it
default to system.mdw?
-----Original Message-----
Hi Martin

Put the following in the code that executes when your database opens:

If CurrentUser = "Admin" then
Application.MenuBar = "Name of Admin Menu"
Else
Application.MenuBar = "Name of User Menu"
End If

****However****
If you have secured your database correctly, you should not be logging in as
Admin, because Admin should have no permissions to any objects. Admin is
the same in every workgroup file, so a user needs only to open your database
with a copy of the default SYSTEM.MDW and s/he will have the same
permissions without username/password that you have logging in as Admin.

You should create a new user in the Admins group, then while logged in as
that user, create a new database, then import everything from the old
database (so that Admin no longer owns the database and its objects), and
finally, remove Admin from the Admins group, and remove all permissions for
all objects from Admin and Admins.

--
Good Luck!

Graham Mandeno [Access MVP]
Auckland, New Zealand

I want a specific menu to launch ONLY when Admin Logs
in. I want everyone else to get the default menu, which
I have stripped down. How do I do this?


.
 
Hi Martin

A database is not linked to a particular workgroup file. The workgroup file
can be specified by a switch on a command line or in a shortcut. If it is
not, then the current default workgroup file is used, but this can be
changed by anyone, by using the Workgroup Administrator (wrkgadm.exe).

I can open your database with my workgroup file with the following command
line:

"C:\Program Files\Microsoft Office\Office\MSACCESS.exe"
"Path to YOUR database" /wrkgrp:"Path to MY workgroup file"

If my workgroup file has no password for Admin, then I'm in with all
permissions.

Have you read the Access Security FAQ? If not, then I *strongly* recommend
you check it out on-line at:
http://support.microsoft.com/support/access/content/secfaq.asp
or you can download a self-extracting file by visiting:
http://support.microsoft.com/?id=207793

Read it, then re-read it, then go to sleep with it under your pillow :-)

--
Good Luck!

Graham Mandeno [Access MVP]
Auckland, New Zealand

Martin said:
Wouldn't that person need to know the Admin Password in
order to change the workgroup file? If they open the
database with the workgroup not available, does it
default to system.mdw?
-----Original Message-----
Hi Martin

Put the following in the code that executes when your database opens:

If CurrentUser = "Admin" then
Application.MenuBar = "Name of Admin Menu"
Else
Application.MenuBar = "Name of User Menu"
End If

****However****
If you have secured your database correctly, you should not be logging in as
Admin, because Admin should have no permissions to any objects. Admin is
the same in every workgroup file, so a user needs only to open your database
with a copy of the default SYSTEM.MDW and s/he will have the same
permissions without username/password that you have logging in as Admin.

You should create a new user in the Admins group, then while logged in as
that user, create a new database, then import everything from the old
database (so that Admin no longer owns the database and its objects), and
finally, remove Admin from the Admins group, and remove all permissions for
all objects from Admin and Admins.

--
Good Luck!

Graham Mandeno [Access MVP]
Auckland, New Zealand

I want a specific menu to launch ONLY when Admin Logs
in. I want everyone else to get the default menu, which
I have stripped down. How do I do this?


.
 
Back
Top