Windows.Forms.WebBrowser Javascript

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • daniel.manges@gmail.com

    Windows.Forms.WebBrowser Javascript

    I'm working on a .NET application using Google Maps, but since the page
    is updated with Javascript, I think I need to use Javascript to get
    directions from the page. Does anybody know how to invoke javascript
    commands on a Windows.Forms.W ebBrowser and get the results ?

  • Martin Honnen

    #2
    Re: Windows.Forms.W ebBrowser Javascript



    daniel.manges@g mail.com wrote:
    [color=blue]
    > I'm working on a .NET application using Google Maps, but since the page
    > is updated with Javascript, I think I need to use Javascript to get
    > directions from the page. Does anybody know how to invoke javascript
    > commands on a Windows.Forms.W ebBrowser and get the results ?[/color]

    A WebBrowser instance has a property named Document
    <http://msdn2.microsoft .com/en-us/library/6s982aac(en-US,VS.80).aspx>
    which is an instance of HtmlDocument
    <http://msdn2.microsoft .com/en-us/library/system.windows. forms.htmldocum ent.aspx>
    and has a method named InvokeScript
    <http://msdn2.microsoft .com/en-us/library/c143s1sy(en-US,VS.80).aspx>

    --

    Martin Honnen --- MVP XML

    Comment

    • daniel.manges@gmail.com

      #3
      Re: Windows.Forms.W ebBrowser Javascript

      Ah! Thank you! I didn't notice the method under the Document element.

      Comment

      Working...