|
Karim
Posts: 170
Joined: 2006-01-02
|
Hi,
adxCOMAddInModuleAddInFinalize event is not fired in Oulook add ins for Office 2010 32 bits and 64 bits
But Events Fired in for Word and Excel add ins.
All works in office 2007
All module is compile with Version 7.3 Hotfix (build 1214) with Delphi XE3 Update 1
Thanks
Karim |
|
Posted 16 Apr, 2013 08:39:25
|
|
Top
|
|
Andrei Smolin
Add-in Express team
Posts: 18819
Joined: 2006-05-11
|
|
Posted 16 Apr, 2013 08:45:19
|
|
Top
|
|
Karim
Posts: 170
Joined: 2006-01-02
|
Hi Andrei,
Microsoft doc not very clear for me
I have this code in my Finalize event. how to make it work on 2010 ?
any event use ?
procedure TAddInModule.adxCOMAddInModuleAddInFinalize(Sender: TObject);
begin
OutlookApp.OnNewMail := nil;
if Assigned(FItems) then
FItems.Disconnect;
end; |
|
Posted 16 Apr, 2013 10:03:13
|
|
Top
|
|
Andrei Smolin
Add-in Express team
Posts: 18819
Joined: 2006-05-11
|
Karim,
Here's a citation from http://www.add-in-express.com/creating-addins-blog/2010/05/04/outlook2010-fast-shutdown/:
There are 2 possible workarounds for those who need to know the moment when Outlook is shutting down to execute their finalization code:
1.You can enable shutdown notifications for your Outlook add-in by adding an additional value to the add-in registration key in the HKCU or HKLM registry hives:
Key: HKCU\Software\Microsoft\Office\Outlook\Add-ins\<YourAddinProgID>
Value: RequireShutdownNotification (DWORD)Setting this value to 1 enables the add-in to receive both events during Outlook shutdown.
2.You can use the Quit event of the ADXOutlookAppEvents class and perform clean-up depending on the OutlookShutdownBehavior property.
Andrei Smolin
Add-in Express Team Leader |
|
Posted 16 Apr, 2013 10:06:51
|
|
Top
|
|
Karim
Posts: 170
Joined: 2006-01-02
|
Hi,
I Try first solution but with RequireShutdownNotification value it doesn't work for me in Outlook 2010 :
Finalize event not fired.
Windows Registry Editor Version 5.00
[HKEY_CURRENT_USER\Software\Microsoft\Office\Outlook\Addins\NovaxelOutlook.Novaxel]
"ADXStartMode"="NORMAL"
"RequireShutdownNotification"=dword:00000001
"Novaxel_Position"=dword:00000001
"Novaxel_Left"=dword:00000064
"Novaxel_Top"=dword:0000008b
"Novaxel_RowIndex"=dword:00000004
[HKEY_CURRENT_USER\Software\Microsoft\Office\Outlook\Addins\NovaxelOutlook.Novaxel\CommandBars]
[HKEY_CURRENT_USER\Software\Microsoft\Office\Outlook\Addins\NovaxelOutlook.Novaxel\CommandBars\Novaxel]
"Position"=dword:00000001
"Left"=dword:00000064
"Top"=dword:0000008b
"RowIndex"=dword:00000004 |
|
Posted 16 Apr, 2013 10:40:12
|
|
Top
|
|
Dmitry Kostochko
Add-in Express team
Posts: 2875
Joined: 2004-04-05
|
Hi Karim,
I suppose you have a per-machine add-in. Is it so? If yes, you need to add the RequireShutdownNotification value to the HKLM registry hive. |
|
Posted 17 Apr, 2013 03:04:08
|
|
Top
|
|
Karim
Posts: 170
Joined: 2006-01-02
|
Hi,
No, no any key about my plug ins HKLM only in HKCU.
But It does not matter because your second solution (with Quit event) works for me and is better.
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Office\Outlook]
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Office\Outlook\Addins]
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Office\Outlook\Addins\Redemption.Addin]
"FriendlyName"="Redemption Helper Outlook Extension"
"LoadBehavior"=dword:00000003
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Office\Outlook\Addins\Search.OutlookToolbar]
"LoadBehavior"=dword:00000003
"FriendlyName"="Windows Search Email Indexer"
"Description"="Windows Search Email |
|
Posted 17 Apr, 2013 08:11:55
|
|
Top
|
|
Dmitry Kostochko
Add-in Express team
Posts: 2875
Joined: 2004-04-05
|
Hi Karim,
32-bit add-ins are located in Wow6432Node if the operating system is 64-bit:
HKLM\SOFTWARE\Wow6432Node\Microsoft\Office\Outlook\Addins
Anyway, thank you for letting us know about the second solution. |
|
Posted 17 Apr, 2013 08:29:26
|
|
Top
|
|
Karim
Posts: 170
Joined: 2006-01-02
|
Thanks a lot for your support ! |
|
Posted 17 Apr, 2013 08:53:47
|
|
Top
|
|