title: Parse multiple XML files with ASP.NET (C#) and return those with particular element
body: <p>Greetings.</p>
  
  <p>I'm looking for a way to parse a number of XML files in a particular directory with ASP.NET (C#). I'd like to be able to return content from particular elements, but before that, need to find those that have a certain value between an element.</p>
  
  <p>Example XML file 1:</p>
  
  <pre><code>&lt;file&gt;
      &lt;title&gt;Title 1&lt;/title&gt;
      &lt;someContent&gt;Content&lt;/someContent&gt;
      &lt;filter&gt;filter&lt;/filter&gt;
  &lt;/file&gt;
  </code></pre>
  
  <p>Example XML file 2:</p>
  
  <pre><code>&lt;file&gt;
      &lt;title&gt;Title 2&lt;/title&gt;
      &lt;someContent&gt;Content&lt;/someContent&gt;
      &lt;filter&gt;filter, different filter&lt;/filter&gt;
  &lt;/file&gt;
  </code></pre>
  
  <p>Example case 1:</p>
  
  <p>Give me all XML that has a filter of 'filter'.</p>
  
  <p>Example case 2:</p>
  
  <p>Give me all XML that has a title of 'Title 1'.</p>
  
  <p>Looking, it seems this should be possible with LINQ, but I've only seen examples on how to do this when there is one XML file, not when there are multiples, such as in this case.</p>
  
  <p>I would prefer that this be done on the server-side, so that I can cache on that end.</p>
  
  <p>Functionality from any version of the .NET Framework can be used.</p>
  
  <p>Thanks!</p>
  
  <p>~James</p>