0

How to invoke JavaScript function written in the HTML from .cs file?

For the Microsoft's Winform control WebBrowser we can invoke the JavaScript function as

Browser.Document.InvokeScript("JavascriptFunction");

We can also pass the parameters from C# to JavaScript function.

How we can achieve this for DotNetBrowser control?

kayess
  • 3,384
  • 9
  • 28
  • 45
user861341
  • 39
  • 1
  • 4

1 Answers1

0

It's resolved. I was missing the braces for the function name. The correct way is browser.ExecuteJavaScript("FunctionName()")

user861341
  • 39
  • 1
  • 4