Office plugin destroys task pane and recreates in when changing Application focus.. sometimes

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

Office plugin destroys task pane and recreates in when changing Application focus.. sometimes
 
Nate Sewell




Posts: 1
Joined: 2019-02-25
Sometimes when changing focus from one application to another (or even switching between instances of Word) the task pane will destroy itself and a new one will be generated in it's place.

We experienced something sort of similar in outlook but there was a field called Cached there which could be set to prevent this from happening.

Is there any sort of similar mechanism in the office addin, or any other way to prevent this from happening?
Posted 19 Mar, 2019 13:24:50 Top
Andrei Smolin


Add-in Express team


Posts: 18829
Joined: 2006-05-11
Hello Nate,

I'm sorry for the delayed response; I've overlooked your post - please forgive me.

I assume you talk about debugging your code: you found out that a task pane instance can be closed and a new one created. In fact, this is expected. The point is Add-in Express tracks the windows of the host application to create your pane and this is possible that the underlying Word/Outlook window is recreated and this causes the issue. I suggest that you use a UserControl: populate it with controls and put it on your pane. Your code can control the UserControl creation at the run time.

What do you think?


Andrei Smolin
Add-in Express Team Leader
Posted 22 Mar, 2019 08:07:25 Top
Andrei Smolin


Add-in Express team


Posts: 18829
Joined: 2006-05-11
Hello Nate,

Hmmm, did you try to reproduce this issue using a simple test add-in? If the issue is reproducible, please call AddinExpress.WD.Log.showMessages() and send us the log.


Andrei Smolin
Add-in Express Team Leader
Posted 22 Mar, 2019 08:29:08 Top