Silverlight 4 脱离浏览器:无需安装即可检查更新?

发布于 2024-09-30 15:12:10 字数 366 浏览 6 评论 0原文

我创建了一个 Silverlight 4 应用程序,该应用程序在浏览器中运行。如您所知,有一个功能可以检查应用程序的新版本是否可用并安装它。

但是,如果我只想检查更新并且不安装更新怎么办?

就我个人而言,我不喜欢默默地自我更新、从互联网下载某些内容的应用程序。所以我希望有以下机制。
- 当应用程序启动时,它会检查更新是否可用
- 如果是这样,我会向用户显示一个消息框,告诉她有更新,并且她可以通过更新按钮下载并安装它
- 用户现在可以决定更新

不幸的是,似乎没有选择只检查更新而不实际下载和安装它。有什么想法,如何实现这一目标?

预先感谢,
坦率

I have created a Silverlight 4 application, that is running out of browser. As you will know, there is a function that is checking if a new version of the app is available and installing it.

But what if I want to only check for the update and not installing it?

Personally, I do not like applications that silently update themselves, downloading something from the internet. So I'd like to have the following mechanism.
- when the app starts, it checks if updates are available
- if so, I show a messagebox to the user, telling her that there is an update and that she can download and installing it via the update-button
- the user can now decide to update

Unfortunately, there seems to be no option to just checking for updates without actually downloading and installing it. Any ideas, how to achieve this?

Thanks in advance,
Frank

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

み零 2024-10-07 15:12:10

您可以自行进行更新检测,方法是在服务器上的应用程序的 XAP 旁边放置一个包含最新版本的小文件。例如:

http://localhost/myawesomeapp.xap
http://localhost/myawesomeapp.xap.ver

当您想检查更新而不下载更新时,您可以随时点击 .ver 文件,检查其中列出的版本,如果比当前正在运行的应用程序更新,则显示 Update 按钮用户。

请注意,此方法还允许您创建更高级的方案,例如提示用户升级到应用程序的不同版本(例如 Pro),或者他们需要升级 Silverlight 才能获取最新版本。

如果您有多个应用程序,您可以在该文件中列出所有应用程序,并在应用程序之间进行交叉推广。

You can roll your own update detection, by having a small file on your server next to the XAP for your app, that contains the latest version. For example:

http://localhost/myawesomeapp.xap
http://localhost/myawesomeapp.xap.ver

When you want to check for updates without downloading them, you can always hit the .ver file, check the version listed in it and if newer then the current running app, show the Update button to the user.

Note that this approach also would allow you to create more advanced scenarios, like prompting the user to upgrade to a different version of the app (Pro for example) or that they need to upgrade their Silverlight to get the latest.

And if you have multiple apps, you can list all of them in that file and do cross-promotion between your apps.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文