protected void Button2_Click(object sender, EventArgs e)
{
int j = 0;
string myString = TextBox1.Text;
char[] ch = myString.ToCharArray();
foreach (char a in ch)
{
if (a.ToString().Equals("a"))
{
j = j + 1;
}
}
TextBox1.Text = j.ToString();
}
Saturday, December 26, 2009
Subscribe to:
Posts (Atom)