WebGadget flag to hide error popups
Posted: Mon Jun 01, 2009 2:09 am
Currently the WebGadget supports only one single flag, but I'd like to suggest
another: #PB_Web_HideErrors. Purpose: Suppress JavaScript error messages.
Sometimes when showing content in a WebGadget, you will get this gem:

So, to avoid this pop-up error message, I've been adding this code to my WebGadgets:
It'd be nice just to do this instead, to save all that extra typing:
Also, I know you can suppress right-clicks with #PB_Web_BlockPopupMenu via
SetGadgetAttributes(), but it'd be nice to do it all one declaration, too:
another: #PB_Web_HideErrors. Purpose: Suppress JavaScript error messages.
Sometimes when showing content in a WebGadget, you will get this gem:

So, to avoid this pop-up error message, I've been adding this code to my WebGadgets:
Code: Select all
WebGadget(#MyWebGadget,4,4,478,247,"")
MyWebGadget.IWebBrowser2=GetWindowLong_(GadgetID(#MyWebGadget),#GWL_USERDATA)
MyWebGadget\put_Silent(#True) ; Suppress JavaScript error messages.
Code: Select all
WebGadget(#MyWebGadget,4,4,478,247,"",#PB_Web_HideErrors)
SetGadgetAttributes(), but it'd be nice to do it all one declaration, too:
Code: Select all
WebGadget(#MyWebGadget,4,4,478,247,"",#PB_Web_HideErrors|#PB_Web_BlockPopupMenu)