在 IE 中以编程方式打开 Web 链接 - 非 Metro 模式

发布于 2025-01-02 16:01:13 字数 53 浏览 4 评论 0原文

有没有办法以编程方式从我的 Metro 应用程序在 IE(非 Metro 模式)中打开链接?

Is there a way to open a link in IE (non-metro mode) from my metro app programmatically?

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

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

发布评论

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

评论(1

极致的悲 2025-01-09 16:01:13

对于 Metro 应用程序,用户可以控制针对 uri 和文件启动的应用程序。

要浏览网页(JavaScript,但 C# 类似):

var uri = new Windows.Foundation.Uri("http://www.microsoft.com");
Windows.System.Launcher.launchUriAsync(uri).then(function () { });

要启动其他应用程序,您应该查看 Windows.System.Launcher 类。

For metro applications users are in control of the applications that launch for uri and files.

To browse to a webpage (JavaScript but the C# is similar):

var uri = new Windows.Foundation.Uri("http://www.microsoft.com");
Windows.System.Launcher.launchUriAsync(uri).then(function () { });

To launch other apps you should look at the Windows.System.Launcher class.

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