Hide partial Command bars

le888

Registered User.
Local time
Today, 08:18
Joined
Dec 10, 2003
Messages
344
Hi,

How can I hide all the command bars except my customize tool bar ? I have hide all my command bars by the following code :
Code:
' Hide all window bar

         Dim i As Integer
            For i = 1 To CommandBars.Count
                CommandBars(i).Enabled = False
            Next i
         DoCmd.RunCommand acCmdWindowHide

I can change “CommandBars(i).Enabled = False” to “CommandBars(i).Enabled = True” but I want only my customized tool to be appear. What is the solution?

Thanks,

Le888
 
Put a test in your loop for your menu name and when that's hit, do not disable it.
 
Guessing that you found that code at this thread...
hide all Access tool bars and menu bars

All you need to do once you have hidden all of the tool bars and menu bars is to run this...
Code:
DoCmd.ShowToolbar "YourCustomToolBar", acToolbarYes
...like I mentioned in that thread.
 
ghudson said:
Guessing that you found that code at this thread...
hide all Access tool bars and menu bars

All you need to do once you have hidden all of the tool bars and menu bars is to run this...
Code:
DoCmd.ShowToolbar "YourCustomToolBar", acToolbarYes
...like I mentioned in that thread.

For me, this don't work.

Le888
 

Users who are viewing this thread

Back
Top Bottom