Show full menus

G

Guest

I have a database that multiple users will be using to view data. One group
of users only need to read the data, but not edit, update or delete. I want
them to have the limited menus from deselecting "Allow full menus" from
Tools:Startup. However, I have other groups using other forms that I want to
have the full menus. Programmatically how do I change this Allow Full Menus
back to true when the form opens and back to false when the form closes.
Thanks. Matt
 
S

Scott McDaniel

You can alter startup properties like this:

currentdb.Properties("AllowFullMenus")

This assumes that you have set this property at least once (it's not added
to the database properties collection until you do so).

However, this works for the NEXT TIME you log onto Access ... so if I log in
and the AllowFullMenus is currently set = True, and you run code to set it =
False, then I'd still get the full menus ... but next time I logged on I
wouldn't get full menus. Startup properties are considered when the database
starts ... thus by the time your code is run, the db is already started ...

Most people do this by build custom toolbars and implement some form of
login scheme (like Access security), then showing/hiding toolbars and
toolbar controls depending on which group the currentuser belongs to.
 
G

Guest

What is the syntax for making a custom toolbar visible and invisible on a
form? Thanks. Matt
 
A

Albert D. Kallal

What is the syntax for making a custom toolbar visible and invisible on a
form? Thanks. Matt

if IsInGroup(CurrentUser,"SuperUser" then

CommandBars("menu bar").Controls("records").
Controls("refresh").Visible = True

end if

if IsInGroup(CurrentUser(),"InvoideDeleteGroup") = true then

CommandBars("myCustomBar").Controls("AdminOptions").
Controls("DleeteInvoice").Visible = True

end if

Note that short cut menus are their own name also:

commandbars("your shortcut name").Contorls("contorlName").visiable = false

And, the above does have some word wrap for readability...but those commands
would be on one line....
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Top