How to display a progress bar when WebView loads a URL, in Android ?

design
extension
beginner

#1

I have developed an application which loads a website link using a WebView. And it’s working fine.

But I am facing problems to display and hide progress bar when the WebView loads a page.

I want to display a progress bar when the WebView loads the main link and internal links of a website and hide progress bar when page is completely loaded

In my application, I have a WebView which loads any URL from the internet. Now, sometimes due to slow networks the page takes a long time to load and the user sees only a blank screen.

I want to show a ProgressBar while the WebView gets loaded and hide the ProgessBar when the WebView gets loaded completely.


#2

Before making any topics/asking questions please do search the forum. Below is a screenshot which explains how to search the community?