ADXAddinModule.CheckForUpdates thread

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

ADXAddinModule.CheckForUpdates thread
does ADXAddinModule.CheckForUpdates need to be invoked using BeginInvoke (dispatched?) 
aweber




Posts: 83
Joined: 2013-11-21
I am working-around the ClickOnce dialog showing during checkforupdates...I am checking in the background, and only if I find a newer version published on the "publish server" do I want to execute the ADXAddinModule.CheckForUpdates() method.

(Really, I have already checked and verified that there IS an update, but this minor redundancy is acceptable to me since we don't have a lot of access to the pseudo-ClickOnce classes.)

Since my method is running on a background thread, my question is whether it is valid to execute the CheckForUpdates() method directly from that thread, or whether I need to dispatch it back to the main application/form thread? Given this is an ADXAddinModule method (not a form-method), I assume the ADX code will dispatch anything it needs to on its own?

If I DO need to dispatch it, what is the easiest way to get the current/host application's dispatcher so I can call BeginInvoke?

Thanks,
AJ

PS: I have seen some of the other workarounds to this "issue" by searching the forum and want to try my approach. Will be happy to post the relevant code when I'm done for review/reuse.
Posted 21 Sep, 2016 09:06:01 Top
Andrei Smolin


Add-in Express team


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

You can call this method from a background thread.


Andrei Smolin
Add-in Express Team Leader
Posted 22 Sep, 2016 04:28:00 Top