bysheriff
bysheriff

Reputation: 48

How to understand document completed using Dj Native Jwebbrowser?

I didnt find any document completed method on JWebbrowser object.

 String git="git(10);"
 webbrowser.executeJavaScript(git);
 String html=webbrowser.getHTMLContent();

this html is include previous page html.Bu I want to take new page. I'm waiting for help.Thanks

Upvotes: 0

Views: 292

Answers (1)

Nico Pretorius
Nico Pretorius

Reputation: 16

You use the listener:

    webBrowser.addWebBrowserListener(new WebBrowserAdapter() {
        @Override
        public void loadingProgressChanged(WebBrowserEvent e) {
            if (e.getWebBrowser().getLoadingProgress() == 100) {
                ....
            }
        }
    });

Upvotes: 0

Related Questions