IWebClientSendRequest Method (WebRequest) |
Sends a GET or POST request.
Namespace:
NScrape
Assembly:
NScrape (in NScrape.dll) Version: 0.4.1.0
SyntaxWebResponse SendRequest(
WebRequest webRequest
)
Function SendRequest (
webRequest As WebRequest
) As WebResponse
WebResponse^ SendRequest(
WebRequest^ webRequest
)
abstract SendRequest :
webRequest : WebRequest -> WebResponse
Parameters
- webRequest
- Type: NScrapeWebRequest
The request to send.
Return Value
Type:
WebResponseThe response from the server.
Remarks
Sends a GET or POST request.
Examplesvar webClient = new WebClient();
var request = new PostWebRequest() {
Destination = new Uri( "http://www.foo.com" ),
RequestData = "step=confirmation&rt=L&rp=%2Flogin%2Fhome&p=0&inputEmailHandle=foo&inputPassword=bar"
};
using ( var response = webClient.SendRequest( request ) ) {
}
See Also