// Arquivo de exemplo: ChildNodes.aspx.cs
using System;
using System.Xml;

public partial class ChildNodes : System.Web.UI.Page {
	protected void Page_Load(object sender, EventArgs e) {
		XmlDocument doc = new XmlDocument();
		doc.Load(@"c:\livro\capitulo22\cadastro.xml");
		XmlElement elem = doc.DocumentElement;
		for (int i = 0; i < elem.ChildNodes.Count; i++) {
			for (int a = 0; a < elem.ChildNodes.Item(i).ChildNodes.Count; a++) {
				Response.Write(elem.ChildNodes.Item(i).ChildNodes.Item(a).InnerText + "<br/>");
			}
		}
	}
}
