Contents - Index - Top


GetCookieSync

Interface AntViewCookieManager

 

Type: Method

Parameters: string uri AntViewCookie Cookie

Returns: Integer

 

 

Retrieve the cookie matching the uri synchronously as an AntViewCookie object in the Cookie parameter.

 

Returns a nonzero error if there's a problem.

 

The function returns:

  0 when the cookies have been found the result is in the Cookies parameter, 

  21 function is already running (can only run one at a time)

  22 function timed out

  23 CookieManager is not connected to WebView2 control

  25 Trying to run a synchronous method from within a WebView2 event

 

 

Examples:

PowerBuilder - Cookie management example

VB6 - Cookie Synchronous example

VFP - Cookie Synchronous example

 

Note: This method does not work in DataFlex due to a bug where DataFlex is unable to pass a IDispatch parameter by reference. This has been reported to Data Access and confirmed as a bug. They suggested to change the interface instead of fixing their code. Last reported for DataFlex 25.0. You can use the asynchronous GetCookies interface instead.

 

See also:

GetCookies

 

Introduced in AntView release 2.0.567

 


AntView - The MS Edge WebView2 ActiveX control Date last changed: 11/05/2025