This documentation is archived and is not being maintained.

Cookie Constructor

.NET Framework 1.1

Initializes a new instance of the Cookie class, conforming to the Netscape specification. In general, an application doesn't need to construct a Cookie class since it is created automatically based on the Set-Cookie header received with the HTTP response.

Overload List

Initializes a new instance of the Cookie class.

[Visual Basic] Public Sub New()
[C#] public Cookie();
[C++] public: Cookie();
[JScript] public function Cookie();

Initializes a new instance of the Cookie class with a specified Name and Value.

[Visual Basic] Public Sub New(String, String)
[C#] public Cookie(string, string);
[C++] public: Cookie(String*, String*);
[JScript] public function Cookie(String, String);

Initializes a new instance of the Cookie class with a specified Name, Value, and Path.

[Visual Basic] Public Sub New(String, String, String)
[C#] public Cookie(string, string, string);
[C++] public: Cookie(String*, String*, String*);
[JScript] public function Cookie(String, String, String);

Initializes a new instance of the Cookie class with a specified Name, Value, Path, and Domain.

[Visual Basic] Public Sub New(String, String, String, String)
[C#] public Cookie(string, string, string, string);
[C++] public: Cookie(String*, String*, String*, String*);
[JScript] public function Cookie(String, String, String, String);

See Also

Cookie Class | Cookie Members | System.Net Namespace

Show: