Upgrading is resetting the ExplorerLayout

Add-in Express™ Support Service
That's what is more important than anything else

Upgrading is resetting the ExplorerLayout
 
Mark Borton


Guest


I have a solution that shows an ADXOLForm in Outlook with a default ExplorerLayout of RightSubpane. Users are allowed to move the form to other regions should they like. When a user performs an update (ClickOnce in my case), the upgrade is always placing the form back in the RightSubpane location even if the user had moved it elsewhere. Is there anything that can be done to "remember" the position?

Thanks!
Posted 26 Sep, 2016 09:18:58 Top
Andrei Smolin


Add-in Express team


Posts: 18794
Joined: 2006-05-11
Hello Mark,

Uninstalling the add-in removes the information that Add-in Express uses to position the form. This info is stored in the ADXXOL subkey of your add-in's key, see {HKLM or HKCU}\Software\Microsoft\Office\Outlook\Addins\{your add-in\ADXXOL}.

The ClickOnce module provides the OnClickOnceAction event. You need to read and preserve the settings from that key when the add-in is being unregistered(ADXClickOnceAction.Unregister). When the add-in is being registered (ADXClickOnceAction.Register) you need to restore the settings. Please find more info in section Customizing ClickOnce installations, see the PDF file in the folder {Add-in Express}\Docs on your development PC.


Andrei Smolin
Add-in Express Team Leader
Posted 26 Sep, 2016 10:24:15 Top
Mark Borton


Guest


Thanks for your quick reply and direction!

-Mark
Posted 26 Sep, 2016 10:36:29 Top
Andrei Smolin


Add-in Express team


Posts: 18794
Joined: 2006-05-11
You are welcome!


Andrei Smolin
Add-in Express Team Leader
Posted 27 Sep, 2016 04:25:48 Top
aweber




Posts: 83
Joined: 2013-11-21
Andrei,

I actually tried this by putting some code in
if (action.HasFlag(ADXClickOnceAction.Unregister))

But it appears that the registry key is already gone by that point. Can you confirm that this event is triggered BEFORE unregister so that we have the correct place to perform any backup or other actions?

Thanks,
AJ
Posted 29 Sep, 2016 14:06:55 Top
Sergey Grischenko


Add-in Express team


Posts: 7233
Joined: 2004-07-05
Hello,

You are right. The 'OnClickOnceAction' event fires after the add-in is unregistered. We will fix this bug in the next build. Please try to use the 'OnUnregister' event of the add-in module. It should work properly.
Posted 30 Sep, 2016 06:57:30 Top