Unregister ADX XLL while Excel is running

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

Unregister ADX XLL while Excel is running
Causes Excel to crash 
Henri Pellemans




Posts: 110
Joined: 2010-05-06
Hi Eugene, there may be a chance that 'something' is wrong with my Win7 computer that is not ADX related, but in the past there was a warning [messagebox] if I tried to unregister an XLL addin while Excel was running.

Please take a look at the ADX source code .. ./ADXLib/ADXXLLModule.cs

I opened the .cs file with Notepad and although I am not so familiar with C# I understand the following lines:

In Notepad line 1869:
private void UninstallXLL()

In Notepad line 1882:
if (this.DisplayAlerts)

In Notepad line 1895:
if (appDisp != null)

In Notepad line 1899:
MessageBox.Show("You have " + ...Excel... + "running at the moment. Please close the application.", this.AddinName, MessageBoxButtons.OK, MessageBoxIcon.Warning);

My opinion is that [on my computer] somehow/somewhere DisplayAlerts is not set to TRUE.

See also Notepad line 306:
Description("Specifies if an alert should be shown when the add-in is being uninstalled and Excel is running.")]



Best regards,

Henri
Posted 29 Feb, 2012 09:54:18 Top
Henri Pellemans




Posts: 110
Joined: 2010-05-06
To avoid misunderstanding: on my WinXP SP3 computer [also with Excel 2010 32-bit] a messagebox shows if I try to unregister an XLL addin while Excel is running.

Henri
Posted 29 Feb, 2012 10:03:24 Top
Eugene Astafiev


Add-in Express team


Posts: 8540
Joined: 2007-07-25
Hi Henri,

You are on the wrong avenue. The DisplayAlerts property of the add-in module is used when an add-in is registered from the setup project (not from Visual Studio). So, how do you register your add-in in Windows XP? Could you please take a screenshot?
.NET, Extended MAPI, Windows Phone & RT
Posted 29 Feb, 2012 13:41:48 Top
Henri Pellemans




Posts: 110
Joined: 2010-05-06
Hi Eugene,

I just have sent some screenshots to the ADX e-mail address.

Best regards,

Henri
Posted 03 Mar, 2012 03:54:18 Top
Eugene Astafiev


Add-in Express team


Posts: 8540
Joined: 2007-07-25
Hi Henri,

Thank you. I will check out my Inbox and get back to you on Monday.
.NET, Extended MAPI, Windows Phone & RT
Posted 04 Mar, 2012 04:58:14 Top
Eugene Astafiev


Add-in Express team


Posts: 8540
Joined: 2007-07-25
Hi Henri,

I have finally reproduced the issue in one of my virtual PCs. The cause of the issue is the High Intergrity Level (is used in case of Windows Vista and 7 and doesn't depend on Add-in Express). I.e. as a result an instance of Excel cannot be found from Visual Studio. Please read more about integrity levels Windows Integrity Mechanism Design and How the Integrity Mechanism Is Implemented in Windows Vista articles in MSDN.
.NET, Extended MAPI, Windows Phone & RT
Posted 05 Mar, 2012 05:03:25 Top
Henri Pellemans




Posts: 110
Joined: 2010-05-06
Hi Eugene,

Thanks for finding out the cause of the issue.

Henri
Posted 05 Mar, 2012 09:13:12 Top