Is there a way to intercept the pages that are requested before they are loaded on webviewgadget ?

Just starting out? Need help? Post your questions and find answers here.
User avatar
skinkairewalker
Enthusiast
Enthusiast
Posts: 799
Joined: Fri Dec 04, 2015 9:26 pm

Is there a way to intercept the pages that are requested before they are loaded on webviewgadget ?

Post by skinkairewalker »

hello everyone !
Is there a way to intercept the pages that are requested before they are loaded on webviewgadget ?

I'm creating a webapp, and I want to prevent the user from accessing a website that shouldn't be in the webview. There is a way to intercept and prevent it from loading, or allow it to load.
infratec
Always Here
Always Here
Posts: 7662
Joined: Sun Sep 07, 2008 12:45 pm
Location: Germany

Re: Is there a way to intercept the pages that are requested before they are loaded on webviewgadget ?

Post by infratec »

I can only say with WebView2 it is possible.
There is a 'navigation callback' and you can block loading the page depending on the return value.

See also the help for the WebGadget()
Post Reply