text box change event [Resolved]

Posted by Sushant under ASP.NET on 4/1/2013 | Points: 10 | Views : 1690 | Status : [Member] | Replies : 1
I want to addition on text change event of 5 attoms.
In this There are 5 text box whose default value should be 0, on change of text addition of 5 atoms price hould be in total

Plz help as early as possible
thanks

Sushat


Responses

Posted by: Satyapriyanayak on: 4/1/2013 [Member] [MVP] Silver | Points: 50

Up
0
Down

Resolved
private void textBox5_TextChanged(object sender, EventArgs e)
{
double i, j, k, l, m,result;
i = Convert.ToDouble(textBox1.Text);
j = Convert.ToDouble(textBox2.Text);
k = Convert.ToDouble(textBox3.Text);
l = Convert.ToDouble(textBox4.Text);
m = Convert.ToDouble(textBox5.Text);
result = i+j+k+l+m;
textBox6.Text = result.ToString();

}

private void Form1_Load(object sender, EventArgs e)
{
textBox1.Text = "0";
textBox2.Text = "0";
textBox3.Text = "0";
textBox4.Text = "0";
textBox5.Text = "0";
}

If this post helps you mark it as answer
Thanks

Sushant, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response