G
Gary
Hello,
I have created a COM Add-in using VB 6 (add-in project). This Add-In
was then compiled into a DLL file and saved. I then created a setup
file for the program using Install Shield Express version 4. (I have
also used the Package and Deployment Wizard to create the setup but it
didn't meet my requirements.)
Everything works great except I have noticed that after uninstalling
the Add-in program that the Add-In program still remains. I used the
Add/Remove Programs in the Control Panel to remove the program and it
did remove the folder where the DLL was installed.
After uninstalling the add-in program, I then went back into Outlook
2000 and noticed my Add-in program still ran. I am not sure why.
Afterwards, after exiting Outlook 2000, I then manually unregistered
the development DLL in another folder – a folder with the development
files (believing that may be the problem). However, again after
staring up Outlook again the Add-in program still ran. I also checked
Tools | Options | Other | Advanced Options | COM Add-ins and the
Add-in program was not listed in the list of Add-ins available. This
was expected since I did uninstall the add-in.
So, what am I doing wrong? I would like to have the Add-in Program
removed completely after running the uninstall using the Add/remove
programs in the control Panel. That seems to have worked since the
installation directory was deleted; however, the program still runs
for some reason. I thought unregistering the DLL using regsvr32 <name
of dll> /u could have solved the problem.
As a side note, I logged off and then relogged back on (on Windows
2000 Start | Shut Down | Log off) . I could have also rebooted my
system. After doing this, I did notice the Add-in program did not run
as expected. So, I am guessing that after a COM Add-in is uninstalled,
that the user must reboot. Does this sound right? Again I wasn't
sure.
This last note most likely is the solution to my problem. Of course,
I would prefer not having a user to reboot after uninstalling my COM
Add-in, but I guess there is no choice to get the program out of
memory and to stop running after it is uninstalled.
One more thing. In my code, I am not exactly sure if or how to close
things out correctly i.e. setting object variable to nothing and to
close out anything else that needs to be shut down. I used the event
IDTExtensibility2_OnDisconnection that may or may not be the correct
event. There is also the event IDTExtensibility2_OnBeginShutdown but I
am not using that event – it only contains comments. That may be why
my Add-In program is still running even after Outlook is closed, but
again I am not sure.
Here is the code in my IDTExtensibility2_OnDisconnection event: (just
dereferencing object variables.)
Set moActiveExplorer = Nothing
Set moNS = Nothing
Set moOL = Nothing
Set oAppMail = Nothing
Set oAppInspector = Nothing
Set oAppInspectors = Nothing
Thanks in advance. Any help is most appreciated.
I have created a COM Add-in using VB 6 (add-in project). This Add-In
was then compiled into a DLL file and saved. I then created a setup
file for the program using Install Shield Express version 4. (I have
also used the Package and Deployment Wizard to create the setup but it
didn't meet my requirements.)
Everything works great except I have noticed that after uninstalling
the Add-in program that the Add-In program still remains. I used the
Add/Remove Programs in the Control Panel to remove the program and it
did remove the folder where the DLL was installed.
After uninstalling the add-in program, I then went back into Outlook
2000 and noticed my Add-in program still ran. I am not sure why.
Afterwards, after exiting Outlook 2000, I then manually unregistered
the development DLL in another folder – a folder with the development
files (believing that may be the problem). However, again after
staring up Outlook again the Add-in program still ran. I also checked
Tools | Options | Other | Advanced Options | COM Add-ins and the
Add-in program was not listed in the list of Add-ins available. This
was expected since I did uninstall the add-in.
So, what am I doing wrong? I would like to have the Add-in Program
removed completely after running the uninstall using the Add/remove
programs in the control Panel. That seems to have worked since the
installation directory was deleted; however, the program still runs
for some reason. I thought unregistering the DLL using regsvr32 <name
of dll> /u could have solved the problem.
As a side note, I logged off and then relogged back on (on Windows
2000 Start | Shut Down | Log off) . I could have also rebooted my
system. After doing this, I did notice the Add-in program did not run
as expected. So, I am guessing that after a COM Add-in is uninstalled,
that the user must reboot. Does this sound right? Again I wasn't
sure.
This last note most likely is the solution to my problem. Of course,
I would prefer not having a user to reboot after uninstalling my COM
Add-in, but I guess there is no choice to get the program out of
memory and to stop running after it is uninstalled.
One more thing. In my code, I am not exactly sure if or how to close
things out correctly i.e. setting object variable to nothing and to
close out anything else that needs to be shut down. I used the event
IDTExtensibility2_OnDisconnection that may or may not be the correct
event. There is also the event IDTExtensibility2_OnBeginShutdown but I
am not using that event – it only contains comments. That may be why
my Add-In program is still running even after Outlook is closed, but
again I am not sure.
Here is the code in my IDTExtensibility2_OnDisconnection event: (just
dereferencing object variables.)
Set moActiveExplorer = Nothing
Set moNS = Nothing
Set moOL = Nothing
Set oAppMail = Nothing
Set oAppInspector = Nothing
Set oAppInspectors = Nothing
Thanks in advance. Any help is most appreciated.