Edit

Share via


WebCredentials Constructors

Definition

Overloads

WebCredentials()

Initializes a new instance of the WebCredentials class to use the default network credentials.

WebCredentials(ICredentials)

Initializes a new instance of the WebCredentials class with the specified credentials.

WebCredentials(String, String)

nitializes a new instance of the WebCredentials class with the user name and password for the account to authenticate.

WebCredentials(String, String, String)

Initializes a new instance of the WebCredentials class with the user name, password, and domain for the account to authenticate.

WebCredentials()

Initializes a new instance of the WebCredentials class to use the default network credentials.

public:
 WebCredentials();
public WebCredentials ();
Public Sub New ()

Applies to

WebCredentials(ICredentials)

Initializes a new instance of the WebCredentials class with the specified credentials.

public:
 WebCredentials(System::Net::ICredentials ^ credentials);
public WebCredentials (System.Net.ICredentials credentials);
Public Sub New (credentials As ICredentials)

Parameters

credentials
ICredentials

The credentials of the account to authenticate.

Applies to

WebCredentials(String, String)

nitializes a new instance of the WebCredentials class with the user name and password for the account to authenticate.

public:
 WebCredentials(System::String ^ username, System::String ^ password);
public WebCredentials (string username, string password);
Public Sub New (username As String, password As String)

Parameters

username
String

The user name of the account to authenticate.

password
String

The password of the account to authenticate.

Applies to

WebCredentials(String, String, String)

Initializes a new instance of the WebCredentials class with the user name, password, and domain for the account to authenticate.

public:
 WebCredentials(System::String ^ username, System::String ^ password, System::String ^ domain);
public WebCredentials (string username, string password, string domain);
Public Sub New (username As String, password As String, domain As String)

Parameters

username
String

The user name of the account to authenticate.

password
String

The password of the account to authenticate.

domain
String

The domain of the account to authenticate.

Applies to