HttpCookieManager.GetCookies(Uri) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Gets an HttpCookieCollection that contains the HttpCookie instances that are associated with a specific URI.
public:
virtual HttpCookieCollection ^ GetCookies(Uri ^ uri) = GetCookies;
HttpCookieCollection GetCookies(Uri const& uri);
public HttpCookieCollection GetCookies(System.Uri uri);
function getCookies(uri)
Public Function GetCookies (uri As Uri) As HttpCookieCollection
Parameters
The URI of the HttpCookie instances desired.
Returns
The HttpCookieCollection that contains the HttpCookie instances that are associated with a specific URI.
Remarks
The GetCookies method creates a new instance of an HttpCookieCollection. Then the HttpCookie instances in the internal collection that are associated with the specified URI are read out and added to the new HttpCookieCollection.
Below are the exceptions that this function throws.
E_INVALIDARG
The uri parameter was a null reference (Nothing in Visual Basic).