Help, Outlook2003 won't quit after call OnDisconnection?

Status
Not open for further replies.
R

ryotyankou

I write a addin, it have inspector wrapper and explorer wrapper. I release

the resource i allocated, but after run codes in OnDisconnection, outlook's

process is still in task manager. Tray icon already disappeared. What should

i check in my codes? please help.


 
K

Ken Slovak - [MVP - Outlook]

Then something in your code is not released if Outlook isn't exiting, and it

does when your code isn't running.

Check all of your Outlook objects to make sure they are being released, as

well as any Office objects. Make sure any timers or threads you started are

closed. If using managed code you may need to call

Marshal.ReleaseComObject() on your objects, try adding calls to GC.Collect()

and GC.WaitForPendingFinalizers() if using managed code.

"ryotyankou " <u48591@uwe> wrote in message

news:9bf4122e055ad@uwe...
> I write a addin, it have inspector wrapper and explorer wrapper. I release
> the resource i allocated, but after run codes in OnDisconnection,
> outlook's
> process is still in task manager. Tray icon already disappeared. What
> should
> i check in my codes? please help.

> >
>
>
 
R

ryotyankou

Hi, ken, i tested my addin in VMware, outlook can quit normally. It seems

that the problem is caused by some other things, i remembered that i killed

the outlook.exe process in task manager manually(Atl + F4) while it quiting

for several times. Maybe this caused the outlook out of its manner.
- wrote:
> Then something in your code is not released if Outlook isn't exiting, and it
> does when your code isn't running.

> Check all of your Outlook objects to make sure they are being released, as
> well as any Office objects. Make sure any timers or threads you started are
> closed. If using managed code you may need to call
> Marshal.ReleaseComObject() on your objects, try adding calls to GC.Collect()
> and GC.WaitForPendingFinalizers() if using managed code.
>
> >I write a addin, it have inspector wrapper and explorer wrapper. I release
> > the resource i allocated, but after run codes in OnDisconnection,
> > outlook's
> > process is still in task manager. Tray icon already disappeared. What
> > should
> > i check in my codes? please help.


 
K

Ken Slovak - [MVP - Outlook]

If under a VM the code quits cleanly then the problem is either some other

Outlook integration code that's running on the problem machine or hung

instances of Outlook. Make sure task manager doesn't show an Outlook process

running before trying again and see if Outlook quits cleanly. If not it's

probably some other code, which you can find by a process of elimination.

"ryotyankou " <u48591@uwe> wrote in message

news:9c160fc274e14@uwe...
> Hi, ken, i tested my addin in VMware, outlook can quit normally. It seems
> that the problem is caused by some other things, i remembered that i
> killed
> the outlook.exe process in task manager manually(Atl + F4) while it
> quiting
> for several times. Maybe this caused the outlook out of its manner.
 
Status
Not open for further replies.
Top