Kiru Marimuthu
Guest
|
Hi
I have to show error message in the custom task pane from Rtd server. Before showing the error I need to check if the taskpane is open or else open it.
Here is the code used to do that check.
var taskPane = AddinModule1.CurrentInstance.adxExcelTaskPanesCollectionItem1.TaskPaneInstance;
if (taskPane.RegionState != ADXRegionState.Normal)
{
taskPane.RegionState = ADXRegionState.Normal;
}
In Rtd server adxExcelTaskPanesCollectionItem1 was not accessible since the modifiers for taskpanecollectionitem is private by default. I changed it to public as shown in the screenshot so that I could access it in the Rtd server.
[img]https://ibb.co/dq8nfS[/img]
Excel.AddinModule1.CurrentInstance.adxExcelTaskPanesCollectionItem1.TaskPaneInstance
Accesing taskpane instance like this leaves the excel running in the background even after closing.
Any help, please?
Thanks
Kiru |
|
Andrei Smolin
Add-in Express team
Posts: 18823
Joined: 2006-05-11
|
Hello Kiru,
To be on the safe side, I'd suggest that you perform this check in the code of the COM add-in, after you receive the corresponding message from the XLL.
Andrei Smolin
Add-in Express Team Leader |
|