XML file creating and reading in C#
To create an XML File from C# code side you can write down a small function that would take input parameters of the values that you want be insert in as values of an XML File. public static bool CreateXml( string JuiceName, string CookieName, int NoOfBreadPackets, int NoOfEggs) { bool IsCreated = false ; try { XmlDocument doc = new XmlDocument(); XmlNode docNode = doc.CreateXmlDeclaration( "1.0" , "UTF-8" , null ); doc.AppendChild(docNode); XmlNode MainNode = doc.CreateElement( "GroceryItems" ); doc.AppendChild(MainNode); XmlNode Node1 = doc.CreateElement( "Juice" ); string str1 = Convert.ToString(JuiceName); Node1.InnerXml = str1; MainNode.AppendChild(Node1); XmlNode Node2 = doc.CreateElement( ...