IWebRequestCreate.Create Method

May 11, 2014

Creates a WebRequest instance.

Namespace:  System.Net
Assembly:  System.Net (in System.Net.dll)

'Declaration
Function Create ( _
	uri As Uri _
) As WebRequest

Parameters

uri
Type: System.Uri
The uniform resource identifier (URI) of the Web resource.

Return Value

Type: System.Net.WebRequest
A WebRequest instance.

ExceptionCondition
NotSupportedException

The request scheme specified in uri is not supported by this IWebRequestCreate instance.

ArgumentNullException

uri is Nothing.

SecurityException

The caller does not have permission to connect to the requested URI or a URI that the request is redirected to.

UriFormatException

The URI specified in uri is not a valid URI.

The Create method must return an initialized instance of the WebRequest descendant that is capable of performing a standard request/response transaction for the protocol without needing any protocol-specific fields modified.

Windows Phone OS

Supported in: 8.1, 8.0, 7.1, 7.0

Windows Phone

Show:
© 2014 Microsoft