Mega Code Archive

 
Categories / C# / XML LINQ
 

Loading an Element with the XElement Load Method

using System; using System.Linq; using System.Collections; using System.Collections.Generic; using System.Xml; using System.Xml.Linq; public class MainClass {     public static void Main() {         XElement xElement = XElement.Load("book.xml");         Console.WriteLine(xElement);     } }