Gets or sets the concatenated values of the node and all its child nodes.
using System;
using System.Xml;
publicclass Test {
publicstaticvoid Main() {
XmlDocument doc = new XmlDocument();
doc.LoadXml("<root>"+
"<elem>some text<child/>more text</elem>" +
"</root>");
XmlNode elem = doc.DocumentElement.FirstChild;
Console.WriteLine("Display the InnerText of the element...");
Console.WriteLine( elem.InnerText );
Console.WriteLine("Display the InnerXml of the element...");
Console.WriteLine(elem.InnerXml);
elem.InnerText = "Text containing <markup/> will have char(<) and char(>) escaped.";
Console.WriteLine( elem.OuterXml );
elem.InnerXml = "Text containing <markup/>.";
Console.WriteLine( elem.OuterXml );
}
}