Returns or sets the position of a command bar. Read/write MsoBarPosition.
MsoBarPosition can be one of these MsoBarPosition constants. |
msoBarBottom |
msoBarFloating |
msoBarLeft |
msoBarMenuBar |
msoBarPopup |
msoBarRight |
msoBarTop |
Example
This example steps through the collection of command bars, docking the custom command bars at the bottom of the application window and docking the built-in command bars at the top of the window.
For Each bar In CommandBars
If bar.Visible = True Then
If bar.BuiltIn Then
bar.Position = msoBarTop
Else
bar.Position = msoBarBottom
End If
End If
Next