View Single Post
  #5 (permalink)  
Old May 28th, 2008, 01:09 AM
KamalRaturi KamalRaturi is offline
Authorized User
Join Date: Aug 2006
Location: delhi, delhi, India.
Posts: 31
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via AIM to KamalRaturi Send a message via Yahoo to KamalRaturi

Hi Sam Judson, Martin Honnen

The code I am using is:

XmlTextWriter xmlWRITER = new XmlTextWriter(Server.MapPath("~/common/xml/SegmentXML.xml"), null);
            xmlWRITER.Formatting = Formatting.Indented;
            xmlWRITER.Indentation = 4;
            xmlWRITER.WriteString(Brand1.ToXml()); //ToXml returns XML-String

and the error is:
Token Content in state Prolog would result in an invalid XML document.

As result It creates Xml document but it is empty.