What is difference between XElement.Load() and XDocument.Load()?

XElement and XDocument are very similar in function, but not interchangeable when you are loading a document from a data source. Use XElement.Load () when you want to load everything under the top-level element, Use XDocument.Load () when you want to load any markup before the top-level element.

Tagged , . Bookmark the permalink.

Leave a Reply