from http://blog.csdn.net/qinwei4072880/article/details/38865179

1、rapidxml不支持中文路径。

2、rapidxml不支持Unicode xml必须为utf-8编码。

解决方法:

#ifdef _UNICODE

setlocale(LC_ALL, "Chinese-simplified"); // 设置中文环境
USES_CONVERSION;
file<> doc(W2A(lpszXml));


setlocale(LC_ALL, "C"); // 还原
#else
file<> doc(lpszXml);
#endif
xml_document<> XmlAnalyse;    
XmlAnalyse.parse<0>(doc.data()); 

 

相关文章:

  • 2022-12-23
  • 2021-09-30
  • 2021-12-04
  • 2021-06-09
  • 2021-12-31
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2022-02-07
  • 2022-01-01
  • 2022-02-09
  • 2022-12-23
  • 2021-08-10
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案