Exporting XML with C#

UltraKiller

New Member
I am Trying to export xml from some data in C#\[code\]XDocument doc = XDocument.Parse(xml);\[/code\]After I save the XML, I found that the XML contains \[code\]<?xml version="1.0" encoding="utf-8"?>\[/code\]Which i did not enter at all, and cause problem like following.\[code\]<?xml version="1.0" encoding="utf-8"?><?xml-stylesheet type="text/xsl" href="http://stackoverflow.com/dco.xsl"?><S> <B> </B></S>\[/code\]I dont want the first row to appear, any ideas?Thanks for your respond.
 
Back
Top