Home All Groups Group Topic Archive Search About

[MsHtml] Execute Javascript in a MsHtml's document

Author
29 Aug 2006 12:37 PM
# Cyrille37 #
Hello,

A HTML document is loaded with the axWebBrowser object, then it is acceded with
the MsHtml object.

We can call a document's html element method, like the Button's Click method :

public class ... {
  ...
  HTMLInputElement theButton = (HTMLInputElement) myDoc.all.item("theButton", 0);
  theButtonclick();
  ...
}

But how to call a document's Javasript function defined like :

<html>
....
<script language="JavaScript" type="text/javascript" >
  function toggleEffect() {
   ...
  }
</script>
....
</html>

Thanks for you help,
Cyrille.

AddThis Social Bookmark Button