-1

I am working on a mshtml C# IE 11 automation based project, when I log in to the website and check the readystate property of the document, it throws a COMException. The same code works for IE 8 without any issue:

while (document.readyState != "complete")
{
//do nothing
}

Can someone please help?

Zameer Ansari
  • 28,977
  • 24
  • 140
  • 219
  • 1
    Can you provide us with the `ToString` of the `COMException`? – Jeff B Sep 12 '14 at 14:15
  • **'doc.readyState'** threw an exception of type 'System.Runtime.InteropServices.COMException'. Member not found. (Exception from HRESULT: 0x80020003 (DISP_E_MEMBERNOTFOUND)) – Zameer Ansari Sep 12 '14 at 14:17
  • @HansPassant - For html document of SHDocVw.InternetExplorer there is no DocumentCompleted event. Can you help?? – Zameer Ansari Sep 12 '14 at 14:57

1 Answers1

2

Try document.readyState instead of doc.readyState

viki
  • 1,178
  • 1
  • 17
  • 22