Answer the question
In order to leave comments, you need to log in
Why is linq query not finding data in xml file?
XML file with data
<?xml version="1.0" encoding="utf-8"?>
<Users>
<User>
<Login>login</Login>
<PasswordMD5>5f4dcc3b5aa765d61d8327deb882cf99</PasswordMD5>
</User>
</Users>
XDocument doc = XDocument.Load(PATH_TO_DATA_FILE);
var user = from User in doc.Root.Elements("Users")
where User.Element("Login").Value == login
select User;
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question