0

Possible Duplicate:
Detect WebBrowser complete page loading

How do I know if my webbrowser finished loading all the page?

how can I display multiple pages in a successive but I do not have the right to go if a page have not completely downloaded on C#

Community
  • 1
  • 1
Abdel
  • 697
  • 2
  • 7
  • 22
  • this is explained here: http://stackoverflow.com/questions/799981/document-ready-equivalent-without-jquery – DoXicK Jan 29 '13 at 12:42

1 Answers1

1

To detect when a WebBrowser control has completed loading, once I've used this code:

void BrowserDocumentCompleted(object sender, WebBrowserDocumentCompletedEventArgs e)
{
  if (e.Url.AbsolutePath != (sender as WebBrowser).Url.AbsolutePath)
  {
      return; 
  }

   //Page Loading Finished
}
eMi
  • 5,018
  • 10
  • 55
  • 103
  • Thank you but it did not function at 100% of the time it works and sometimes not I do not know why sometimes it does not wait the end of the page load: s – Abdel Jan 29 '13 at 16:13