Hi every one
This works good:
private void textBox1_TextChanged(object sender, EventArgs e)
{
bool f = true;
if (textBox1.Text != "" && f)
{
f = false;
decimal d = Convert.ToDecimal(textBox1.Text.Replace(",", ""));
textBox1.Text = d.ToString("###,###,###");
string s = textBox1.Text + " ";
textBox1.Select(textBox1.Text.Length, 1);
}
}