是否可以从网页启动 Silverlight 4 OOB 应用程序?
我计划构建一个下载管理器应用程序,并希望能够在用户单击网站按钮时启动该应用程序。该应用程序显然已经需要安装在客户端计算机上。
需要使用 Silverlight 编写的原因有几个,但它们与问题并不真正相关。我提到它只是为了让人们不建议我使用其他技术。
I'm planning to build a download manager application and would like to be able to launch the application when a user clicks a button the site. The application would obviously already need to be installed on the client machine.
There are a few reasons why this needs to be written using Silverlight, but they're not really relevant to the question. I only mention it so that people don't suggest that I use another technology.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(4)
对另外两篇文章进行了一些混搭 [1]和 [2< /a>]。
但当然这仅适用于 Windows,不适用于 Mac。在那里,您必须回退到 @michael-s-scherotter 风格的解决方案。
Doing a bit of a mash up from two other posts [1] and [2].
But of course this will only work for Windows not Mac. There you will have to fallback to the @michael-s-scherotter style solution.
是的。这是一个例子:
http://www.silverlight.net/content/samples/apps/ facebookclient/sfcquickinstall.aspx
Yes. Here is an example:
http://www.silverlight.net/content/samples/apps/facebookclient/sfcquickinstall.aspx
我发现了一个技巧,可以从浏览器中的 silverlight 应用程序启动已安装的 silverlight OOB。这两个应用程序都应该被签署并具有更高的信任度。
我希望这个技巧对你有用:)
I found a trick that launches the installed silverlight OOB from the silverlight app in-browser. Both applications should be singed and have the elevated trust.
I hope this trick is useful to you :)
如果您同意用户每次点击该应用程序时都安装该应用程序,则这是可能的。
您还应该将应用程序设置为要求对其 OOB 设置提高信任度。
只需在启动时卸载应用程序(例如,在主窗口构造函数中):(
卸载代码取自这篇文章:http://www.wintellect.com/blogs/sloscialo/programmatically-uninstalling-silverlight-out-of-browser-application)
It is possible if you agree to install the app each time the user clicks on it.
You also should set the app to require elevated trust in its OOB settings.
Just uninstall the app on startup (for example, in main window constructor):
(the code for uninstall was taken from this post: http://www.wintellect.com/blogs/sloscialo/programmatically-uninstalling-silverlight-out-of-browser-application)