I have a string like this: "<Root><Child>Hey</Child></Root>"
How can I convert this to an XElement
Object?
I have a string like this: "<Root><Child>Hey</Child></Root>"
How can I convert this to an XElement
Object?
Use XElement.Parse method like below
XElement xmlTree = XElement.Parse("<Root><Child>Hey</Child></Root>");
Console.WriteLine(xmlTree);