Skip to content Skip to sidebar Skip to footer

How To Stop Swipetorefresh Progressbar In Webview?

I'm new with Android development. I got trouble using SwipeToRefresh option in WebView. I'm trying to solve it from a mounth now and after trying several codes, it's not working. A

Solution 1:

I had the same problem and i found the question in another thread:

final SwipeRefreshLayout swipeLayout = 
   (SwipeRefreshLayout)this.findViewById(R.id.swipeToRefresh);
        swipeLayout.setOnRefreshListener(new SwipeRefreshLayout.OnRefreshListener() {
            @Override
            public void onRefresh() {
                myWebView.reload(); // refreshes the WebView

                if (null != swipeLayout) {
                    swipeLayout.setRefreshing(false);
                }
            }
        });

Post a Comment for "How To Stop Swipetorefresh Progressbar In Webview?"