I have a VBA program that uses IE Automation to query a web site a classical way: Const URL = "xxxx" Dim ieApp As InternetExplorer Dim oHTMLDoc As HTMLDocument
ieApp.Navigate URL
Do While ieApp.Busy: DoEvents: Loop
Do Until ieApp.ReadyState = READYSTATE_COMPLETE: DoEvents: Loop
Set oHTMLDoc = ieApp.Document
.....etc
For some reasons, I have to use the InternetExplorer object - I can't use MSXML2 library to query the site. Later in the program, the result of the query is pure XML - which is a pain to parse using HTML routines.
So my simple question: how can I transfer a HTMLDocument into an MSXML2.DOMDocument ?
Dim oXMLDoc As MSXML2.DOMDocument
Set oXMLDoc = oHTMLDoc 'Fails
Thank you.