Hello,
I try to write these characters to an XML file. but in the XML file it shows:
> < & instead. how can i write correctly to the XML file or at least read correctly(assign the innertext to a variable)
here is my code for writing to XML file:
XmlElement title= xmldoc.CreateElement("Title");
title.InnerText = txtName.Text;
newBook.AppendChild(title);

how to write >, <, &to XML file
Roberto Venturelli
//Well im still get > & lt; and & back.//
Note that you get special characters back without escaping.
//the XML file also contains these formats instead of '<>&'.//
This is expected. These characters are reserved for mark-up, and must be escaped if used not for mark-up. Please read the official XML spec available at http://www.w3.org/TR/REC-xml/ for more information.
Nick Y
Chris Wu
Quazarman