how to do a document completed void to a web browser variable?

Yairk_kaufmann 6 Reputation points

I want to do a function when the browser complete to load the document but it's in variable

An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
10,642 questions
{count} votes

1 answer

Sort by: Most helpful
  1. Timon Yang-MSFT 9,586 Reputation points

    I think you should need WebBrowser.DocumentCompleted Event.

            private void Form1_Load(object sender, EventArgs e)  
                WebBrowser WebBrowser = new WebBrowser();  
                WebBrowser.DocumentCompleted += WebBrowser_DocumentCompleted;  
            private void WebBrowser_DocumentCompleted(object sender, WebBrowserDocumentCompletedEventArgs e)  
               //do your function  

    If the response is helpful, please click "Accept Answer" and upvote it.
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.