I have a separate form with a WebBrowser control. The script won't run if I try to invoke it from another form but it does run if I invoke it in the same form.
Dim JS As New jsEncrypt
JS.WebBrowser.Navigate(New Uri(Environment.CurrentDirectory() & "\web\javascript.html"))
Dim str As String = JS.WebBrowser.Document.InvokeScript("eisu")
Application.Run(JS)
Console.WriteLine(str)