howto POST data to URL?

  • Thread starter Thread starter S Moran
  • Start date Start date
S

S Moran

i have to rewrite a VBScript in C#. the VBS is currently using
Microsoft.XMLHTTP to POST data and then the ResponseText property to check
if the POST was successful. can this be done simply in C#?
 
Hello,

check the documentation for the WebRequest class.

Kind regards,
Henning Krause
 
thank you. for some reason when i say "using System.Net", this does not give
me the normal functionality. for example:

WebRequest request = WebRequest.Create(http://www.yahoo.com);

the "WebRequest" does not change color as if it were recognized.

also typing "request." does not pop up a list of available options...

any ideas what might be wrong?
 
If you are attempting an asynch post (XmlHttp), I would consider looking at
AJAX (ajax.asp.net). AJAX is the asynch postback for .NET. If you use any
other method, you are going to take a postback to the server that is
synchronous (whole page refreshes).

--
Gregory A. Beamer
MVP; MCP: +I, SE, SD, DBA
http://gregorybeamer.spaces.live.com
Co-author: Microsoft Expression Web Bible (upcoming)

************************************************
Think outside the box!
************************************************
 
Back
Top