Add A Button To The Menu Bar When Opening Workbook
I found your coding very helpful, but I haven't been able to delete the menu
item automatically when I close my file. Can you provide me with the coding
for that?
Thanks,
Chris
"JW" wrote:
Sure.
Sub addbar()
Dim MenuItem As CommandBarButton
Set MenuItem = _
Application.CommandBars("Worksheet Menu
Bar").Controls.Add(Type:=msoControlButton)
MenuItem.Style = msoButtonCaption
MenuItem.Caption = "Caption Here"
MenuItem.OnAction = "macronamehere"
Set MenuItem = Nothing
End Sub
HTH
-Jeff-
Minitman wrote:
Greetings,
I need to place a button, with code, onto the menu bar when I open a
particular workbook from any machine in my network.
I can do it manually, but I can't figure out how to do it with code.
Any suggestions, ideas or possible links that could shed some light as
to how to proceed?
Any help is appreciated.
-Minitman
|