Note that there are some explanatory texts on larger screens.

plurals
  1. POonPageStart called many times and onPageFinished not called for single page
    primarykey
    data
    text
    <p>My question is different from <a href="https://stackoverflow.com/questions/6719814/onpagefinished-never-called-webview">this</a> one guys.. I wany my progress dialog start when page load starts and end when the page load finished in my webview. My problem is the progress dialog starts and never get dismissed.I have set break points it shows that the progress dialog starts and get dismissed many times then it starts and not get dismissed even after page load completed. My question is why the onPageStarted getting executed many time for a single page loading? and why onPageFinished not called after completion of page load?</p> <pre><code> myWebView.setWebViewClient(new WebViewClient(){ @Override public boolean shouldOverrideUrlLoading(WebView view, String url) { myWebView.loadUrl(url); return true; } @Override public void onPageStarted(WebView view, String url, Bitmap favicon) { super.onPageStarted(myWebView, url, favicon); Log.d("mytag","Page Loading Started"); //myURLProgressDialog= ProgressDialog.show(WebviewExampleActivity.this, "Page Loading", "Wait for a moment..."); } @Override public void onPageFinished(WebView view, String url) { Log.d("mytag","Page Loading Finished!"); super.onPageFinished(myWebView, url); //myURLProgressDialog.dismiss(); } }); </code></pre> <p>My self tagged filtered Log is Like this for loading single page:</p> <pre><code> 10-06 10:32:49.298: DEBUG/mytag(508): Page Loading Started 10-06 10:32:49.998: DEBUG/mytag(508): Page Loading Started 10-06 10:32:50.048: DEBUG/mytag(508): Page Loading Finished! 10-06 10:32:50.048: DEBUG/mytag(508): Page Loading Started 10-06 10:33:00.898: DEBUG/mytag(508): Page Loading Finished! </code></pre> <p>When I am clicking link on already loaded page it works fine. Here is Log:</p> <pre><code>10-06 10:59:25.098: DEBUG/mytag(543): Page Loading Started 10-06 10:59:30.889: DEBUG/mytag(543): Page Loading Finished! </code></pre>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload