开发者

httprequest.GetResponse() hang?

开发者 https://www.devze.com 2023-01-30 16:03 出处:网络
I meet a issue that is related to the following code , anyone know 开发者_运维百科how to fix it?

I meet a issue that is related to the following code , anyone know 开发者_运维百科how to fix it?

code snippet

 using (HttpWebResponse response = (HttpWebResponse)request.GetResponse())
            using (Stream dataStream = response.GetResponseStream())
            {
                StreamReader reader = new StreamReader(dataStream);
                responseString = reader.ReadToEnd();
            }


Look into "Aysncronous HttpWebResponse"'s

http://www.informit.com/guides/content.aspx?g=dotnet&seqNum=582

0

精彩评论

暂无评论...
验证码 换一张
取 消