471,579 Members | 1,943 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,579 software developers and data experts.

invisible toolbar

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 ?

May 28 '06 #1
2 1605
ADezii
8,827 Expert 8TB
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 ?
This should do the trick:
On Error Resume Next

Dim MyCommandBar As CommandBar

For Each MyCommandBar In Application.CommandBars
If MyCommandBar.Name <> "Toolbar1" Then
MyCommandBar.Visible = False
End If
Next MyCommandBar
May 28 '06 #2

"solar" <sp*******@gmail.com> schreef in bericht news:11**********************@u72g2000cwu.googlegr oups.com...
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 ?


I could not find a solution but maybe the command
DoCmd.RunCommand acCmdShowOnlyWebToolbar
will help you.
This command seems to make all toolbars invisible except the Toolbar "web" (if visible)

So I would try:
DoCmd.RunCommand acCmdShowOnlyWebToolbar
DoCmd.ShowToolbar "Web", acToolbarNo
DoCmd.ShowToolbar "Toolbar1", acToolbarYes

Arno R
May 28 '06 #3

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

15 posts views Thread by Greg Schmidt | last post: by
6 posts views Thread by Juan Pedro Gonzalez | last post: by
1 post views Thread by Alfredo Barrientos | last post: by
reply views Thread by XIAOLAOHU | last post: by
reply views Thread by lumer26 | last post: by
reply views Thread by Vinnie | last post: by
1 post views Thread by lumer26 | last post: by
reply views Thread by lumer26 | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.