MS Word Invalidate the Ribbon from one template into another

P

Premek

Hello

background of problem
I work with a Word 2000 template where I have an own menu. Also I have a
Word 2007 template with the same menu but rewrote for Ribbon. The menus are
appeared at the "Add-Ins" tab. These templates are attached with some
documents. actually only the old one is attached.
Because the old template is referenced to the new template (VBA's menu -
Tools - Reference - "NewTemplate.dotm") the menus are appeared twice (old and
new). Because of this I use "getVisible" callback and I check if a active
document is attached with the old or with the new template. According to
attached template I set up the "returnedVal" variable.

How it works
When a user open the 2000 template they can hit a button that does some
changes and the most important change is that a document is "reattached" with
the new one (i mean Office 2007 template)

What is my problem
When document is "reattached" with the 2007 template the old menu will be
disappeared = it's OK, but the new menu isn't being appeared. I have to close
the document and reopen it then it is appeared.

What I have tried
1, after "reattaching" I tried reopen the document via VBA = doesn't work
2, after "reattaching" I tried invalidate the ribbon = doesn't work
Something like this = [VBA Code]NewTemplate.RibbonVariable.Invalidate[VBA
Code]
3, use the "DoEvents" method = doesn't work

Any help will be appreciated. I can discuss to somebody who is interested
in, via Skype, email, MSN ...
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top