C# comparing two files regex problem
<p>what I'm trying to do is open a huge list of files (about 40k records, and match them on a line in a file that contains 2 millions records.  And if my line from file A matches a line in file B write out that line.</p>

<p>File A contains a bunch of files without extensions and file B contains full file paths including extensions.</p>

<p>i'm using this but i cant get it to go...</p>

<p>string alphaFilePath = (@"C:\Documents and Settings\g\Desktop\Arrp\Find\natst_ready.txt");</p>

<pre><code>            List&lt;string&gt; alphaFileContent = new List&lt;string&gt;();

            using (FileStream fs = new FileStream(alphaFilePath, FileMode.Open))
            using (StreamReader rdr = new StreamReader(fs))
            {
                while (!rdr.EndOfStream)
                {
                    alphaFileContent.Add(rdr.ReadLine());
                }
            }

            string betaFilePath = @"C:\Documents and Settings\g\Desktop\Arryup\Find\eble.txt";

            StringBuilder sb = new StringBuilder();

            using (FileStream fs = new FileStream(betaFilePath, FileMode.Open))
            using (StreamReader rdr = new StreamReader(fs))
            {
                while (!rdr.EndOfStream)
                {
                    string betaFileLine = rdr.ReadLine();
string matchup = Regex.Match(alphaFileContent, @"(\\)(\\)(\\)(\\)(\\)(\\)(\\)(\\)(.*)(\.)").Groups[9].Value;
                    if (alphaFileContent.Equals(matchup))
                    {
                        File.AppendAllText(@"C:\array_tech.txt", betaFileLine);
                    }
                }
            }
</code></pre>

<p>This doesnt work because the alphafilecontent is a single line only and i'm having a hard time figuring out how to get my regex to work on the file that contains all the file paths (Betafilepath)</p>

<p>here is a sample of the beta file path.</p>

<p>C:\arres_i\Grn\Ora\SEC\DBZ_EX1\Nes\001\DZO-EX00001.txt</p>

<p>Here is the line i'm trying to compare from my alpha
DZO-EX00001</p>
