C#StreamWriter问题 [英] C# StreamWriter Problem

查看:141
本文介绍了C#StreamWriter问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在这里遇到了一个很好的问题:

我的页面接收到一个请求,然后它发送一个请求回到另一个服务器,其中包含与orignal requess相同的所有参数,并等待响应答案应该是有效的。或者无效

然后我的页面发回原始响应女巫被丢弃。


当我在local.host上运行时,一切都很完美。

我将我的文件上传到服务器,然后运行页面,它在这行代码崩溃:

i got a nice problem here:
my page recieves a request, it then sends a request back to the other server with all of the same params as the orignal requess, and waits for a responce the responce should be "Valid" or "Invalid"
and then my pages sends back the orignal response witch is discarded.

When i run on local.host everything works perfectly.
I upload my files to the server, and run the page and it crashes at this line of code:

展开 | 选择 | Wrap | 行号

推荐答案

我认为当你调用RequestStream时,它会执行一些预调用操作。到服务器......也许?
I think when you call the RequestStream it does somesort of "pre-call" to the server....maybe?


bypre-call你的意思是?


等待回复
by "pre-call" you mean?

waiting for reply


就像你说获取请求流一样,它向服务器发送部分请求POST / somepage .asp HTTP / 1.1"然后当你完成流程后,它会发送其余信息吗?

内容长度:10


asdfghjklq"
Like when you say get request stream, it sends a partial request to the server "POST /somepage.asp HTTP/1.1" and then when you finish with the stream it sends the rest?
"Content-Length: 10

asdfghjklq"


这篇关于C#StreamWriter问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆