开发者

ClickOnce check for update without executing app

I work in a service organization where users of our internal tools are often disconnected. It is often the case that service engineers on service assignments are "stranded" with an outdated version of some internal tool.

These tools are deployed using ClickOnce publish VS2010 .NET4 . If the users run all their apps while still connected to corporate network, they would get a notification that a new version was available. As the number of various tools increase, the chance increases that some app is not updated.

Is it possible to automate this process, by a batch file or something? So that the engineers just need to run one file when connected to corporate nw to get all the newest 开发者_StackOverflowversions of their installed tools?

Added:

An easier way of saying it would be to have "something like Windows update" operating on corporate net, but for internal ClickOnce apps.


Very interesting question. I can't think of a quick way to do this, but it's definitely possible.

I would create another ClickOnce app whose job is to update the other ClickOnce apps. This app needs the url of each app's .application file. If all engineers are supposed to have all apps, that's easy. If not, maybe you could look through their start menu and find all the ClickOnce Application Reference files. Those files contain the url.

Next, just launch the url and pass a query string argument... http://server/MyApp/MyApp.application?UpdateOnly=true

In the startup of your applications, you can check the query string argument and shut down the app if it's run with UpdateOnly=true.

One side note. If you set the minimum required version of each of your apps to the latest version, users won't get prompted with the new version dialog. Seems like you'd want to do that or the user would still have to pay attention and do a lot of clicking.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜