简体   繁体   中英

Self-Updating (from network) Wix setup project

I already found this question: Self updating application install with WIX?

But the accepted answer is from 2009. So I`am asking me, if there is a better solution than: ClickThrough

Or maybe there is a running example or a tutorial how to create a self-updating Wix Project?

I want to create a simple installer, which checks for updates (like ClickOnce) and automatically downloads them.

It's not that difficult to add your own code to the app for an MSI-based upgrade. At the client end you need code that knows the ProductVersion, UpgradeCode and ProductCode of the installed version. This needs to call a webservice method that (typically) queries a database to see if there is an updated ProductVersion for the ProductCode (which would usually be a patch) or an updated ProductVersion for the UpgradeCode (which would be a major upgrade). Then you'd download it. IMO none of this code is particularly challenging. The only data the app needs to be hardcoded with is the UpgradeCode of the installed product from which its ProductCode can be determined (using MsiEnumRelatedProducts and equivalents) and from the returned ProductCode you can get ProductVersion (using MsiGetProductInfo or equivalent).

You can't really offer to install it unless you're sure the user has the appropriate privileges.

For products installed with WiX bundles I assume you'd do the same kind of thing for the bundle's Product and Upgrade codes, version.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM