I load this file into forms controls - without problems, but if i change the value of some controls and want to update particular xml node - nothing happens. For example, i want to change the price of apple, according to my TextBox1.Text:
file01 = new XmlDocument();
file01.Load(filePath);
XmlElement root = file01.DocumentElement;
XmlNodeList nodes = root.SelectNodes("/Food/Fruit");
foreach (XmlNode node in nodes)
{
if (node["name"].InnerText == "apple")
{
node["price"].InnerText = textBox1.Text;}}
I also tried TextBox1.Text convert to string - also nothing happend. XML file remains unchanged.
Any suggestion, pls. How to finish ?

VulpesPosted Apr 15, 2012, 1:22 PM
file01.Save(filePath);
VulpesPosted Apr 15, 2012, 2:52 PM
MementoPosted Apr 15, 2012, 2:51 PM
ThankYou, Man.