从 Windows 窗体打开 URL [英] Open a URL from Windows Forms
本文介绍了从 Windows 窗体打开 URL的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我正在尝试从 Windows 窗体提供到我公司网站的链接.我想表现得很好,并使用用户首选的浏览器启动.
I'm trying to provide a link to my company's website from a Windows Form. I want to be well behaved and launch using the user's preferred browser.
从 Windows 窗体应用程序在用户的默认浏览器中打开 URL 的最佳方法是什么?
What is the best way to open a URL in the user's default browser from a Windows Forms application?
推荐答案
这篇文章将走你通过它.
简答:
ProcessStartInfo sInfo = new ProcessStartInfo("http://mysite.com/");
Process.Start(sInfo);
这篇关于从 Windows 窗体打开 URL的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文