textBox1.Text = "abc"; int count = textBox1.Text.Count(f => f == 'a');
int count1 = Regex.Matches(textBox1.Text, "a").Count;
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)