MSXML4: Cannot load XML
-
Hi, I am trying to load the following XML through MSXML4 APIs. But it does not load. It says "Reference to undeclared namespace prefix 'ns0'". The code is:
CComBSTR bstrXML = "Arun"; MSXML2::IXMLDOMDocumentPtr pDoc(__uuidof(MSXML2::DOMDocument30)); VARIANT_BOOL b1 = pDoc->loadXML(bstrXML.m_str);
Could anyone tell me how to resolve this ? Thanks in advance, Arun. -
Hi, I am trying to load the following XML through MSXML4 APIs. But it does not load. It says "Reference to undeclared namespace prefix 'ns0'". The code is:
CComBSTR bstrXML = "Arun"; MSXML2::IXMLDOMDocumentPtr pDoc(__uuidof(MSXML2::DOMDocument30)); VARIANT_BOOL b1 = pDoc->loadXML(bstrXML.m_str);
Could anyone tell me how to resolve this ? Thanks in advance, Arun.I couldn't replicate it but i'd try: - Change DOMDocument30 to DOMDocument40 if you don't have a good reason to not to do it. - Have you added
using namespace MSXML2;
Marc Soleda. ... she said you are the perfect stranger she said baby let's keep it like this... Tunnel of Love, Dire Straits.