title: Compare string array to "FileInfo / GetFiles"
body: <p>I have a <code>string</code> array that contains all the "<em>Important files</em>" names that I want to keep in a folder. The folder contains txts like "spam.txt", or such, aswell as 1 file named "vital.txt"</p>
  
  <p><strong>The goal would be to move all the other files except important ones to another folder</strong>.</p>
  
  <p>This is what I would do :</p>
  
  <pre><code>string[] importantFiles = { "vital.txt", "primordial.dll" };
  
  // with currentDir.GetFiles correctly set
  foreach (FileInfo fileScanner in currentDir.GetFiles()) 
  {
     foreach (string s in importantFiles)
     {
        // Without the "!", works normally, returns matching files
        if (!fileScanner.Name.Equals(s))
        {
             MessageBox.Show(
               "This is SUPPOSED to be a non matching file : " + fileScanner.Name);
        }
        else // nothing
  </code></pre>
  
  <p>The problem I'm facing with every method I've tried is to "reverse" the matching process. Finding matching file is ok, but filtering the bad one seems impossible to me.</p>