Try this:
vb Code:
listBox1.Items.Clear();
using (StreamReader sr = new StreamReader(textBox1.Text + @"\Game\Game.LOG"))
{
while (sr.Peek() > -1)
{
string ln = sr.ReadLine();
if (ln.Contains(" joined the match."))
{
string values = (from Match m in Regex.Matches(ln, @"""(.*?)""", RegexOptions.IgnoreCase)
select m.Value).ToArray()[0];
//string status = ln.Contains("disco") ? "" : "";
textBox1.Text += values.Replace((char)34, '\n') + Environment.NewLine;
}
}
}
string[] arr = textBox1.Lines;
textBox1.Text = String.Join(Environment.NewLine, arr.Distinct().ToArray());
This will remove all the duplicates. Assuming that your display "2/16" is correct. I'm not sure how your validating that.