XElement.Parse (String) load an XElement from a string that contains XML. : Elements « XML LINQ « C# / C Sharp






XElement.Parse (String) load an XElement from a string that contains XML.

 
using System;
using System.Linq;
using System.Xml.Linq;
using System.Collections;
using System.Collections.Generic;


public class MainClass{
   public static void Main(){
        XElement xmlTree = XElement.Parse("<Root> <Child> </Child> </Root>");
        Console.WriteLine(xmlTree);
   }
}

   
  








Related examples in the same category

1.Calling the First Elements Prototype
2.Calling the Second Elements Prototype
3.XElement.Parse (String, LoadOptions) loads an XElement from a string that contains XML