Word 2007 AddIn with Ribbon Toolbar

T

TobyG

Hello

I have to load my AddIn on demand.

But when I set loadBeaviour to 8 and something bad happens for example word
process is killed.
The Ribbon Toolbar remains visible in Word. The AddIn is NOT loaded.

If I use LoadBeaviour 3 all is working well, because the AddIn seams to be
refreshing Word and the Ribbon.

How is a good practise to initialze an AddIn which needs loadbehaviour 3 for
function correctly but fully initialized on a demand do initialize call.

thank you in advance

tobias
 
K

Ken Slovak - [MVP - Outlook]

If custom ribbon UI is visible that means your code is supplying the XML for
that ribbon.

Make sure to set up your ribbon callbacks so they check a flag in your code
to see if they should supply ribbon XML. That could be set for example in
OnConnection() or OnStartupComplete().

If for some reason your addin gets disconnected or errors out, clear that
flag. Then check it also in any getVisible() or other callbacks.

That way you don't supply the XML if not connected, and don't keep it
visible if disconnected or some error state fires your disconnect code.

One thing on load on demand settings is that if your addin is actually
connected after the ribbon UI has been requested your UI won't show up.
 

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