SAL

  博客园  :: 首页  :: 新随笔  :: 订阅 订阅  :: 管理

2013年6月5日

摘要: 内网用户或代理上网的用户使用using System.IO; using System.Net;public string get_html(){string urlStr = "http://www.domain.com/"; //設定要獲取的地址HttpWebRequest hwr = (HttpWebRequest)HttpWebRequest.Create(urlStr); //建立HttpWebRequest對象hwr.Timeout = 60000; //定義服務器超時時間WebProxy proxy = new WebProxy(); //定義一個網關對象pr 阅读全文

posted @ 2013-06-05 09:47 SAL 阅读(459) 评论(0) 推荐(0) 编辑