CookieValue Property | ||
Syntax
Remarks
Data Type
Example' Save the cookies set by a previous request to this server for ' a resource so that they can be sent back with the next request nCookies = HttpClient1.CookieCount ReDim strCookieName(nCookies) ReDim strCookieValue(nCookies) ' Enumerate the available cookies and store them in the array; ' a more complex implementation could use the GetCookie method ' to check for additional information about the cookie, such ' as whether the cookie should be stored locally on the system For nIndex = 0 To nCookies - 1 strCookieName(nIndex) = HttpClient1.CookieName(nIndex) strCookieValue(nIndex) = HttpClient1.CookieValue(nIndex) Next ' Clear any previously set headers HttpClient1.ClearHeaders ' Set each of the cookies that were stored in the array For nIndex = 0 To nCookies - 1 HttpClient1.SetCookie strCookieName(nIndex), strCookieValue(nIndex) Next ' Request the next resource from the server and store ' the data in the strResult string buffer nError = HttpClient1.GetData(strResource, strResult) See Also
|
||
Copyright © 2024 Catalyst Development Corporation. All rights reserved. |