D
David Thielen
Hi;
Ok, I don't know why but this works (I hate solutions like this
because you never know if they will continue to work in the future).
For this call (the second one)
Office.CommandBar MainMenuBar = thisApplication.CommandBars["Menu
Bar"];
MainMenuBar.Controls.Add( Office.MsoControlType.msoControlPopup,
Type.Missing, Type.Missing, before, false);
Make sure that 4th parameter is false. If it is, then you can set the
CustomizationContext, create your menu, and if the
CustomizationContext is later changed, your added menu will stay.
I set the CustomizationContext to my template. And when I am done, I
set it back to what it was when my init code started. It all works
great with the false.
thanks - dave
ps - If there is anyone here from MS who can say if this is a
"correct" way to handle this, I would appreciate it.
Ok, I don't know why but this works (I hate solutions like this
because you never know if they will continue to work in the future).
For this call (the second one)
Office.CommandBar MainMenuBar = thisApplication.CommandBars["Menu
Bar"];
MainMenuBar.Controls.Add( Office.MsoControlType.msoControlPopup,
Type.Missing, Type.Missing, before, false);
Make sure that 4th parameter is false. If it is, then you can set the
CustomizationContext, create your menu, and if the
CustomizationContext is later changed, your added menu will stay.
I set the CustomizationContext to my template. And when I am done, I
set it back to what it was when my init code started. It all works
great with the false.
thanks - dave
ps - If there is anyone here from MS who can say if this is a
"correct" way to handle this, I would appreciate it.