VB.NET Office-Outlook com add-in seperated from underlying RCW problem ??

  • Thread starter aidan.hutchinson
  • Start date
A

aidan.hutchinson

On creating a com add-in for Office applications that works in both
Word & Outlook, Excel etc...
Im finding that once the add-in is installed sometimes it works ok but
sometimes the code execs but no toolbar and the following message is
relayed in error trapping.....

'Com object that has been seperated from its underlying RCW can not be
used'

When the add-in works ok, when i quit say Word or Outlook the second
time i come to load the same app, the add-in does not work ie no code
behind the toolbar is being executed.

ive decribed this reaction in a previous post as i initally thought it
was the installer creating the problems with the registary or
something.

I cannot run the com add-in in debug mode, the VS IDE just launches the
app i choose for debug but the com add-in does not exec for debug??

All of which was working at somepoint, last month but suddenly wouldnt
play ball.

if anyone can help id be greatfull !?
 
M

Mark Bower [MSFT]

When the add-in works ok, when i quit say Word or Outlook the second
time i come to load the same app, the add-in does not work ie no code
behind the toolbar is being executed.

As I recall, new in Office 2003, if your add-in throws an exception that you
fail to trap then Office will automatically disable it so it is not loaded
next time. Could this be related?

--
Mark Bower
Microsoft
http://blogs.msdn.com/bowerm

This post is provided 'as-is' without warranty and confers no rights.
 
A

aidan.hutchinson

Cheers Mark,

this kind of explains things, obviously theres some code somewhere
which is causing this issue so more debugging is needed.

Presumerby if i cure this will the add-in will work properly in the
IDE's Debug mode rather than doing what i described above ?
 

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