Reputation: 61
I'm trying to figure out how can I reload page automatically if WebView fail to reach URL. I don't know if onWebResourceError
can help me.
Thanks in advance!
Upvotes: 1
Views: 2177
Reputation: 61
I found that onWebResourceError
was the key.
here is the solution:
onWebResourceError: (WebResourceError error) {
_myController.loadUrl("http://connectivitycheck.gstatic.com/generate_204");
},
Upvotes: 1