Last active
February 11, 2020 22:51
-
-
Save evanricard/4aed2940dedf9d60bc738e3539022e94 to your computer and use it in GitHub Desktop.
GetXMLValue
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private static string GetXmlValue(string id, string getData, XDocument xdoc) | |
{ | |
return xdoc.Root.Descendants("girl").Elements(). | |
Where(node => node.Name == "id" && node.Value == id). | |
Single<XElement>().NodesAfterSelf(). | |
Where(values => ((XElement)values).Name == getData). | |
Cast<XElement>().Single<XElement>().Value; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment