C# 調(diào)用ie打開(kāi)URL地址
//方法一
Process ps = new Process();
string yourURL = "http://www.fqjyxx.com";
ps.StartInfo.FileName = "iexplore.exe";
ps.StartInfo.Arguments = yourURL;
ps.Start();
string yourURL = "http://www.fqjyxx.com";
ps.StartInfo.FileName = "iexplore.exe";
ps.StartInfo.Arguments = yourURL;
ps.Start();
//方法二比較直接,但不好用,不知道原因
* //System.Diagnostics.Process.Start(textBox2.Text.Trim());
*/
*/
我的代碼使用方法1 OK
if (textBox2.Text.Trim().Equals(""))
{
MessageBox.Show("請(qǐng)輸入視頻的URL地址!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
return;
}
Process ps = new Process();
string yourURL = textBox2.Text.Trim();
ps.StartInfo.FileName = "iexplore.exe";
ps.StartInfo.Arguments = yourURL;
ps.Start();
{
MessageBox.Show("請(qǐng)輸入視頻的URL地址!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
return;
}
Process ps = new Process();
string yourURL = textBox2.Text.Trim();
ps.StartInfo.FileName = "iexplore.exe";
ps.StartInfo.Arguments = yourURL;
ps.Start();
posted on 2014-09-15 15:59 void 閱讀(3230) 評(píng)論(0) 編輯 收藏 所屬分類(lèi): C#