Move Next To End XML Element - CSharp System.Xml

CSharp examples for System.Xml:XML Element

Description

Move Next To End XML Element

Demo Code

/*//  w w w . j  av  a  2 s. c o m
* Copyright (c) 2005 Poderosa Project, All Rights Reserved.
* $Id: XMLUtil.cs,v 1.2 2005/04/20 08:45:48 okajima Exp $
*/
using System.Text;
using System.Xml;
using System.Collections;
using System;

public class Main{
        public static bool MoveNextToEndElement(XmlReader reader) {
         while(reader.NodeType!=XmlNodeType.EndElement) {
            if(reader.IsEmptyElement) break;
            if(!ReadSubstantialNode(reader)) return false;
         }
         return ReadSubstantialNode(reader); //?????????EndElement?"?????
      }
}

Related Tutorials