You can set the UpdateType to "Nothing", then, before you manually check for updates, set the UpdateType back to "Automatic".
Hi,
I am using wybuild for updating my software. I am using Autoupdater control to update my application. I want to update the application on certain conditions only. so i am checking for updates from my code using autoupdater methods.
Now my question is if I set updatemode of autoupdater control to 'Automatic' then will it also check check for updates on server ? Because i do not want control to check for updates. I only want to check for updates from code only.
For now it is checking for updates automatic that i do not want. Please help me on this
You can set the UpdateType to "Nothing", then, before you manually check for updates, set the UpdateType back to "Automatic".
But I dot want autoupdater control to check for updates automatically. I only want to check for updates from code only.So if i set updatemode to 'DoNothing' then it will work. Right?
Yes, that's what I was saying. Set the UpdateType to "DoNothing" in Visual Studio. Then, in your code, when you manually check for updates, set the UpdateType to "Automatic" just before you call ForceCheckForUpdates(). The reason you want to do it like this, is you're telling the AutomaticUpdater to download the updates, extract them, and prepare them for installation if there's an update available when you manually check for updates.
OK so before auBackend.ForceCheckForUpdate();, I changed updatetype to Automatic. But I again have to set updatetype to 'DoNothing' Correct?
Now I am setting again updatetype to 'DoNothing' in 1) auBackend_UpToDate2) auBackend_UpdateSuccessful3) auBackend_UpdateFailed4) auBackend_CheckingFailed
events. so is this fine or anywhere else i have to set updatetype to 'DoNothing' again?
Thanks,
You don't need to set the UpdateType to "DoNothing" other than at design time in Visual Studio. The reason this is the case is that when your app starts up the AutomaticUpdater checks if the UpdateType is anything other than DoNothing. If it is, and the right number of days has passed, the AutomaticUpdater checks for updates. Otherwise if the UpdateType is "DoNothing" at startup the AutomaticUpdater will never automatically check for updates.