Click here to Skip to main content
15,901,373 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi everyone
I Send my string with UploadString method in WebClient in my client app
VB
Dim response As String = MyWebClient.UploadString("http://localhost:1062/recivedata.ashx", "POST", "This is a string test")

But how can i receive it in my ASHX page in server?
Thanks.
Posted
Updated 20-May-13 20:41pm
v3

1 solution

C#
public void ProcessRequest(HttpContext context)
     {
         var requestInputStream = new StreamReader(HttpContext.Current.Request.InputStream);
         var requestContent = requestInputStream.ReadToEnd();
         requestInputStream.Close();
     }
 
Share this answer
 
Comments
Sina asefi 21-May-13 2:58am    
Thank you very much man

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900