zoukankan      html  css  js  c++  java
  • C# 读取网页

     //using System.Net;
            //using System.IO;
            private void button1_Click(object sender, EventArgs e)
            {
                WebRequest req = WebRequest.Create("http://stock.business.sohu.com/q/bc.php?code=000607");
                try
                {
                    WebResponse result = req.GetResponse();
                    Stream ReceiveStream = result.GetResponseStream();
                    StreamReader readerOfStream = new StreamReader(ReceiveStream, System.Text.Encoding.GetEncoding("GB2312"));
                    string temp = readerOfStream.ReadToEnd();
                    richTextBox1.Text = temp;
                }
                catch { }
            }
  • 相关阅读:
    k8s nod rc service 使用
    Linux $() 与 ${}
    Linux set
    Linux 上传下载 rz 与sz
    Linux !的使用
    K8s创建pod yaml文件详解
    Kubernetes 安装
    Python 生成器
    k8s 使用详解
    微信 网页授权
  • 原文地址:https://www.cnblogs.com/baishahe/p/1080619.html
Copyright © 2011-2022 走看看