danikuper
Registered User.
- Local time
- Today, 15:31
- Joined
- Feb 6, 2003
- Messages
- 147
Hi!
I've read lots of threads on how to hide and show toolbars and tried everything possible however I am still having problems with my application.
Here's what's happening. I have security in place so every user has one userID and passwd. There's a startup form in place that checks which user is logged in and opens the appropriate switchboard.
Now I want to hide the menu bar and have displayed only a custom toolbar (called Cash) I created.
In the Open event of my startup form I included the following:
Private Sub Form_Open(Cancel As Integer)
DoCmd.ShowToolbar "Menu Bar", acToolbarNo
DoCmd.ShowToolbar "Cash", acToolbarYes
DoCmd.Close
If CurrentUser = "salesrep" Then DoCmd.OpenForm "Welcome - Sales"
If CurrentUser = "accting" Then DoCmd.OpenForm "Welcome Accounting"
If CurrentUser = "mngrs" Then DoCmd.OpenForm "Welcome - Managers"
End Sub
If I open the database as someone from the Admins group and double-click the startup form, when it opens it does exactly what the code tells it to do: hide menu bar and show Cash toolbar. However when the user (salesrep, for example) logs in, nothing happens with the toolbars.
Any ideas?! Please?
Thanks!!!!!
I've read lots of threads on how to hide and show toolbars and tried everything possible however I am still having problems with my application.
Here's what's happening. I have security in place so every user has one userID and passwd. There's a startup form in place that checks which user is logged in and opens the appropriate switchboard.
Now I want to hide the menu bar and have displayed only a custom toolbar (called Cash) I created.
In the Open event of my startup form I included the following:
Private Sub Form_Open(Cancel As Integer)
DoCmd.ShowToolbar "Menu Bar", acToolbarNo
DoCmd.ShowToolbar "Cash", acToolbarYes
DoCmd.Close
If CurrentUser = "salesrep" Then DoCmd.OpenForm "Welcome - Sales"
If CurrentUser = "accting" Then DoCmd.OpenForm "Welcome Accounting"
If CurrentUser = "mngrs" Then DoCmd.OpenForm "Welcome - Managers"
End Sub
If I open the database as someone from the Admins group and double-click the startup form, when it opens it does exactly what the code tells it to do: hide menu bar and show Cash toolbar. However when the user (salesrep, for example) logs in, nothing happens with the toolbars.
Any ideas?! Please?
Thanks!!!!!