Click here to Skip to main content
15,923,087 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
xml content with control characters:
XML
<root>
<node command="&#27;">some info</node>
</root>




my VC++ code,compiled with VC++ 6.0
C++
#import "MSXML3.dll" named_guids

 CoInitialize(NULL);

 MSXML2::IXMLDOMDocumentPtr xmldoc = NULL;

 HRESULT hr = xmldoc.CreateInstance(MSXML2::CLSID_DOMDocument);
 VARIANT_BOOL success = xmldoc->load( CComVariant("c:\\test.xml") );
 if (success == VARIANT_TRUE)
 {
  AfxMessageBox("load ok");
 }
 else
 {
  AfxMessageBox("load fail");
 }

 xmldoc = NULL;
 CoUninitialize();
Posted
Updated 12-Apr-10 5:11am
v4

1 solution

Checking the parseError object's members would help. See this example[^].
:)
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900