It works fine with my OutLook inbox, but with GMail, no success.
Anybody with a helpful suggestion ?
The embryonic code I use is as follows :
Code: Select all
EnableExplicit
Define.s gmail
; gmail = "https://mail.google.com/mail/inbox"
gmail = "https://mail.google.com/mail/u/0/#inbox"
gmail = "https://outlook.live.com/mail/#/inbox"
Procedure NavigationCallback(gadget, Url$)
; This example does display the PureBasic.com website. Inside the callback procedure
; the navigation to the 'News' site will be avoided (#False returned), but allowed
; for all other sites (#True returned).
If Url$= "http://www.purebasic.com/news.php"
MessageRequester("", "No news today!")
ProcedureReturn #False
EndIf
ProcedureReturn #True
EndProcedure
If 0 = OpenWindow(0, 0, 0, 1024, 1000, "GMail", #PB_Window_SystemMenu | #PB_Window_ScreenCentered)
End
EndIf
WebGadget(0, 10, 10, 1000, 980, gmail)
SetGadgetAttribute(0, #PB_Web_NavigationCallback, @NavigationCallback())
Repeat
Until WaitWindowEvent() = #PB_Event_CloseWindow