In one of my applications I use the addin template methode and than have the
toolbar available from that template. The line .CommandBars("MyBar").Enabled
= True is the code that doesn't work with word 2000. The .Commandbars.count
is always 107 regardless if I add other templates using the Addin methode.
This works in Word 97 however in Word 2000 it does not work and I get the
invalide procedure error message. This is the code in question:
Constant MYTEMPLATE = "C:\mytemplate.dot"
Set appWD = GetObject("", "Word.Application")
' Add MyTemplate to Word
.AddIns.Add MYTEMPLATE, Install:=True
.CommandBars("MyBar").Enabled = True