CSharp examples for System.Xml:XML Element
Find Child in XmlElement
using System.Xml; using System.Collections.Generic; using System.Collections; using System;/*from www.j a v a 2 s.c om*/ public class Main{ public static XmlElement FindChild(XmlElement parent, string childNodeName){ foreach (XmlNode node in parent.ChildNodes) { if (node.NodeType == XmlNodeType.Element && node.Name == childNodeName) { return (XmlElement)node; } } return null; // couldn't find it. } }