CookieCollection.Add Method

Definition

Adds a Cookie to a CookieCollection.

Overloads

Add(Cookie)

Adds a Cookie to a CookieCollection.

Add(CookieCollection)

Adds the contents of a CookieCollection to the current instance.

Adds a Cookie to a CookieCollection.

public:
 virtual void Add(System::Net::Cookie ^ cookie);
public void Add (System.Net.Cookie cookie);
abstract member Add : System.Net.Cookie -> unit
override this.Add : System.Net.Cookie -> unit

Parameters

cookie
Cookie

The Cookie to be added to a CookieCollection.

Exceptions

cookie is null.

See also

Add(CookieCollection)

Adds the contents of a CookieCollection to the current instance.

public:
 void Add(System::Net::CookieCollection ^ cookies);
public void Add (System.Net.CookieCollection cookies);
member this.Add : System.Net.CookieCollection -> unit
Public Sub Add (cookies As CookieCollection)

Parameters

cookies
CookieCollection

The CookieCollection to be added.

Exceptions

cookies is null.

Remarks

Each Cookie is read from the CookieCollectioncookies parameter and added to the current instance.

See also

Applies to