Page Navigation and updation of document using web browser control in c#
<p>Hi i'm new in using webrowser control.A website contains grid with page navigation which holds multiple links.each of that page is navigated using ajax.I couldn't able to get the page updated in that document and want to navigate the page automatically using webbrowser control in c#.</p>

<p>I'm using the below code for navigating the page.But,I can only able to navigate the  links in current document.</p>

<p>My requirement is, I have to navigate all the links in that website and fetch the data.</p>

<pre><code>private void webBrowser1_DocumentCompleted(object sender, 
                                  WebBrowserDocumentCompletedEventArgs e)
{
    int k = 2;
    HtmlElementCollection links = webBrowser1.Document.GetElementsByTagName("A");

    foreach (HtmlElement link in links)
    {
        string lin = Convert.ToString(k);
        if ((link.InnerText == lin))
        {
            link.InvokeMember("Click");
            while ((webBrowser1.ReadyState != WebBrowserReadyState.Complete))
            {
                Application.DoEvents();
            }
            k++;
        }
    }
}
</code></pre>
