且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

加载到XElement时如何从文件中删除字符?\

更新时间:2023-12-05 22:49:16

除非看到xml 文件的内容,否则很难找出问题中指定的添加n1:的原因. .但是,从问题描述中似乎可以看出,原因可能是由于在元素中添加了name space,在这方面,以下参考文献可能会有所帮助.
http://***.com/questions/1231396/xelement-default- namespace-on-attributes-provides-unexpected-behaviour [ ^ ]
http://msdn.microsoft.com/en-us/library/bb387075.aspx [ ^ ]
http://***.com/questions/1453564/how-to-addor-ignore-xml-namespace-when-using-xelement-load [
Unless the contents of the xml file are seen, it is difficult to figure out the cause for addition of n1: specified in the question. But, it appears from the question description that the reason may be due to the addition of name space to the element and in this regard the following references may be helpful.
http://***.com/questions/1231396/xelement-default-namespace-on-attributes-provides-unexpected-behaviour[^]
http://msdn.microsoft.com/en-us/library/bb387075.aspx[^]
http://***.com/questions/1453564/how-to-addor-ignore-xml-namespace-when-using-xelement-load[^]