Creating a manual toolbar in the VBE gets saved in position, but using VBA is deleted on exit

Occasional Contributor

The manual way to add a VBE toolbar is via View, Toolbars, Customize, New, then give it a name. dock it with the other toolbars. When you exit Excel and then restart Excel, the toolbar name and position are saved with Excel. However, if you use VBA, like so: Set cmdMyBar = Application.VBE.CommandBars.Add("VBE", msoBarFloating, True, False) and then exit Excel, the toolbar disappears and doesn't return on load up. i think this is a question for a microsoft engineer to determine why this behavior happens.





1 Reply
best response confirmed by DanMcG (Occasional Contributor)