Data at the root level is invalid. Line 1, position 1 -why do I get this error while loading an xml file?

后端 未结 1 1335
日久生厌
日久生厌 2020-12-01 12:06

Data at the root level is invalid. Line 1, position 1 -why I get this error while load xml file

this my code:

XmlDocument xmlDoc=new XmlDocument();
x         


        
相关标签:
1条回答
  • 2020-12-01 12:51

    The LoadXml method is for loading an XML string directly. You want to use the Load method instead.

    0 讨论(0)
提交回复
热议问题