Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

invisible toolbars 1

Status
Not open for further replies.

peljo

Technical User
Mar 3, 2006
91
BG
With my command DoCmd.ShowToolbar "Toolbar1", acToolbarYes i make my
toolbar Toolbar1 visible.I want at the same time make all other
toolbars on the screen invisible,regardless how they are
called.Sometimes i have
different toolbars shown and i am interested in a command that does
not refer toa specific toolbar, but makes all the toolbats on the
screeninvisible.Is it possible ?
 
How are ya peljo . . .

. . . and this . . .
Code:
[blue]   Dim cb As Object
   
   For Each cb In CommandBars
      If cb.Name = "[purple][b]YourToolBarName[/b][/purple]" Then
         cb.Visible = True
      ElseIf cb.Visible Then
         cb.Visible = False
      End If
   Next

End Sub[/blue]

Calvin.gif
See Ya! . . . . . .
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top