<MasterCode>
<Uid>119</Uid>
<Name>Juan Gabriel MONTE</Name>
<Category>LastName</Category>
</MasterCode>
<MasterCode>
<Uid>120</Uid>
<Name>Atilla SELEK</Name>
<Category>FirstName</Category>
</MasterCode>
<MasterCode>
<Uid>121</Uid>
<Name>barbosa filisa</Name>
<Category>LastName</Category>
</MasterCode>
This is an example of my xml file. i want to filter only the names that comes under the category last name. how to filter it and print the names in text file with C#?. Please help Thank u in advance.