hi please help.
I have an xml document.. with a nodename is written in capital letters.. so i need to edit that as small letters..
thanks in advance.
Loading
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Mallikarjuna MPosted May 7, 2008, 2:51 AM
I will explain that once again, just c the following xml,
now i need to change the xmlnode name
Is it possible? If so how can i acheive that..
Blocked AccountPosted May 7, 2008, 2:33 AM
By using this code u can update your xml file.
XmlNodeList newXMLNodes = XMLDom.SelectNodes("/PNode/Node1");
foreach(XmlNode newXMLNode in newXMLNodes)
//Updating data where "Node1" is "sree" with "kambham"
if(newXMLNode.InnerText == "sree")
newXMLNode.InnerText = "kambham";
XMLDom.Save("Path of your XML file");
XMLDom = null;
//The above step updates xml file where ever it finds "sree" with "kambham"