public static void UpdateAttribute(XmlElement XmlElement, string attributeName, string newValue) { XmlAttribute attrTemp = null; attrTemp = (XmlAttribute)XmlElement.Attributes.GetNamedItem(attributeName); attrTemp.InnerText = newValue; }