Is it possible within VBA in Excel to create a new item in the menus or toolbars?
Thanks, DaveBo
Printable View
Is it possible within VBA in Excel to create a new item in the menus or toolbars?
Thanks, DaveBo
Yes, use the Office.CommandBarButton object and declare an
object "Public WithEvents myMenuItem as
Office.CommandBarButton" in a class instanciated in the
WorkBook_Open event.
HTH
Try looking at these downloadable examples:
http://www.erlandsendata.no/english/...ommandbars.htm
The "CommandBars with custom icons" creates a new commandbar and adds buttons, but you can use the example to learn how to add buttons to an existing toolbar.
Thanks