code_junkie

WebBrowser document cast not valid

Nov 12th, 2011
109
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.62 KB | None | 0 0
  1. Exception Type: System.InvalidCastException
  2. Message: Specified cast is not valid.
  3. Source: System.Windows.Forms
  4. Stack Trace:
  5. at System.Windows.Forms.UnsafeNativeMethods.IHTMLDocument2.GetLocation()
  6. at System.Windows.Forms.WebBrowser.get_Document()
  7. at InteriorHealth.EmbeddedBrowser.frmMain.CardRead(String strData) in E:DevelopTestProjectfrmMain.cs:line 265
  8. at MyTest.frmMain.prtCardReader_DataReceived(Object sender, SerialDataReceivedEventArgs e) in E:DevelopTestProjectfrmMain.cs:line 355
  9.  
  10. this.webKiosk.Document.InvokeScript(ConfigurationState.CardReader.Error.FireJavaScriptMethod);
  11.  
  12. CardRead(strCardData_m);
Add Comment
Please, Sign In to add comment