Can I call a JavaScript function from the .NET Compact Framework through a WebBrowser control?
It works with the Navigate () method. I just tried it using Pocket PC emulator for Windows Mobile 5.0.
For instance:
webBrowser1.DocumentText = @"<html><head> <script type='text/javascript'> function doIt() { alert('hello again'); return 'i did it!'; } </script> </head><body>hello!</body></html>"; webBrowser1.Navigate(new Uri("javascript:doIt()"));