void

          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();


          //方法二比較直接,但不好用,不知道原因

          //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();

          posted on 2014-09-15 15:59 void 閱讀(3230) 評(píng)論(0)  編輯  收藏 所屬分類(lèi): C#


          只有注冊(cè)用戶(hù)登錄后才能發(fā)表評(píng)論。


          網(wǎng)站導(dǎo)航:
           
          主站蜘蛛池模板: 怀宁县| 湾仔区| 江都市| 新昌县| 新余市| 泰顺县| 隆德县| 长治县| 凤山县| 汉阴县| 边坝县| 资兴市| 定兴县| 和平区| 循化| 五常市| 新沂市| 翼城县| 尖扎县| 纳雍县| 济宁市| 晋中市| 清镇市| 绩溪县| 临沧市| 垦利县| 石河子市| 竹山县| 且末县| 巴林左旗| 开平市| 乳源| 盐城市| 平南县| 乌审旗| 友谊县| 阳高县| 满洲里市| 辽中县| 香河县| 手游|