Hi Chuck,
You can use the IDs instead of the names/captions. That should be safe, as they haven't changed from version to version or between language versions, as far as I know.
Instead of
CommandBars("Menu Bar").Controls("Tools")
you can use
' "Tools" menu on menu bar:
CommandBars.FindControl(ID:=30007)
Below are the IDs for the standard dropdown menus on the menu bar, a couple of non-standard ones, as well as some submenus.
Regards,
Klaus
MenuFile (File Menu) 30002
MenuEdit (Edit Menu) 30003
MenuView (View Menu) 30004
MenuInsert (Insert Menu) 30005
MenuFormat (Format Menu) 30006
MenuTools (Tools Menu) 30007
MenuTable (Table Menu) 30008
MenuWindow (Window Menu) 30009
MenuHelp (Help Menu) 30010
MenuFormatBackground (Format Background Submenu) 1706
MenuAutoTextList (Insert AutoText Submenu) 3260
MenuOrgChartInsert (Inserts an additional box to the organization chart) 6925
MenuMacro 30017
MenuNotesFlow (Notes Flow Menu) 30083
MenuSendTo (Send this document to...) 30095
MenuWork (Work Menu) 30100
MenuRevisions (Revisions Submenu) 30138
MenuAutoText 30181
MenuLanguage 30182
MenuTableInsert (Inserts rows, columns, or cells in a table) 30444
MenuTableDelete (Deletes rows, columns, or cells in a table) 30445
MenuTableSelect 30446
MenuTableConvert (Converts text to a table or a table to text) 30447
MenuFrameset (Format Frameset Submenu) 30452
MenuTableAutoFitLong 30460
MenuOrgChartLayout (Layout) 31158
MenuDiagramLayout (Diagram Layout) 31179
MenuDiagramConvertTo (Convert To) 31180
> I have an English global template that has custom menus built and saved
> with it. Some of my users have German and Swedish versions of Word.
[quoted text clipped - 11 lines]
> thanks,
> --- chuck
CC - 16 Mar 2005 04:36 GMT
Klaus,
Thanks for the reply -- I've changed my code and it is now working
for both Geerman and Swedish editions. I have no idea where you found
this list, but I'll certainly save it off for future reference.
-- chuck