'Activity module
Sub Process_Globals
'These global variables will be declared once when the application starts.
'These variables can be accessed from all modules.
End Sub
Sub Globals
'These global variables will be redeclared each time the activity is created.
'These variables can only be accessed from this module.
Dim CookieManager1 As CookieManager
Dim WebView1 As WebView
End Sub
Sub Activity_Create(FirstTime As Boolean)
WebView1.Initialize("WebView1")
Activity.AddView(WebView1, 0, 0, 100%x, 100%y)
' call SetAcceptCookie after WebView has been initialized
CookieManager1.SetAcceptCookies(True)
' load a webpage that requires a login
Dim Url As String
Url="https://accounts.google.com/signin/v2/identifier?service=CPanel&flowName=GlifWebSignIn&flowEntry=ServiceLogin" ' change this to your login page
WebView1.LoadUrl(Url)
End Sub
Sub Activity_Resume
End Sub
Sub Activity_Pause (UserClosed As Boolean)
End Sub
Sub WebView1_PageFinished (Url As String)
Log("WebView1_PageFinished Url = "&Url)
If CookieManager1.HasCookies Then
Log("Cookies: "&CookieManager1.GetCookie(Url))
Else
Log("No cookies found")
End If
End Sub