Load XmlDocument Sample : XmlDataDocument « XML « C# / CSharp Tutorial






using System;
using System.IO;
using System.Xml;

public class MainClass
{
  public static void Main()
  {
    try
    {
      XmlDataDocument myXmlDocument = new XmlDataDocument();

      myXmlDocument.Load("Sample.xml");

      myXmlDocument.Save(Console.Out);
    }
    catch (Exception e)
    {
      Console.WriteLine("Exception: {0}", e.ToString());
    }
  }
}








30.9.XmlDataDocument
30.9.1.Load XmlDocument Sample
30.9.2.ReadData As Xml