HTTP Post request

G

Guest

How can i use system.net or any other namespace provided by .net framework to send a HTTP Post request
I was using Winhttp object in VB6, now i want to use the functionality provided by .net framework

Razbir
 
G

Guest

Use webrequest and webresponse

dim req as webreques
dim rsp as webrespons

req = WebRequest.Create("someurl.asp"

req.Method = "POST

req.ContentType = "text/xml" or "application/x-www-form-urlencoded" <-- Use what ever your planning to sen

'send some info here using the req.GetRequestream metho

rsp = req.getrespons

'retrieve info from the response using rsp.GetResponseStream metho
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top