基本信息
源码名称:C# 检查代理IP是否可用 实例程序源码
源码大小:0.07M
文件格式:.rar
开发语言:C#
更新时间:2017-10-26
   友情提示:(无需注册或充值,赞助后即可获取资源下载链接)

     嘿,亲!知识可是无价之宝呢,但咱这精心整理的资料也耗费了不少心血呀。小小地破费一下,绝对物超所值哦!如有下载和支付问题,请联系我们QQ(微信同号):78630559

本次赞助数额为: 2 元 
   源码介绍

代理IP检测程序

 

 

{
            try
            {

            string ip = txtIP.Text.Trim();
            string point = txtPoint.Text.Trim();
            httpHelper.Proxy = new WebProxy(ip ":" point, true);
            httpHelper.ResponseEncoding = "utf-8";
            string txtresult = httpHelper.GetString("http://www.ip.cn/");

            richTextBox1.Text = txtresult;
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message);
                //throw;
            }

            return;

 

            ////proxy = new WebProxy("http://111.161.126.100:80", true);
            //proxy = new WebProxy("http://" ip ":" point, true);
            //GlobalProxySelection.Select = proxy;
            //req = (HttpWebRequest)WebRequest.Create("http://www.ip138.com/ips138.asp?ip=" ip "&action=2");
            //res = (HttpWebResponse)req.GetResponse();
            ////StreamReader readStream = new StreamReader(res, System.Text.Encoding.GetEncoding("GB2312"));
            
            //s = res.GetResponseStream();
            //r = new StreamReader(s,System.Text.Encoding.GetEncoding("GB2312"));
            //richTextBox1.Text = r.ReadToEnd();
            //r.Close();
            //s.Close();
            //res.Close();
           // MessageBox.Show(ip);
        }