Skip to content

Adding two numbers in csharp

Asked Mar 9, 2012, 2:43 AM EST2 answers
Share
LinkedInX
i have two text box.

company cost 1000

 tax 100

total  i want 1100


how to do please help me

2 Answers

Know the answer? Post it. Somebody with the same question will find it here.

  • Abdur Rehman
    0
    int x=int.Parse(txtbox1.text);
    int y=int.Parse(txtbox2.text);

    int  total=x+y;

    txtbox3.text=total.tostring();
    0
  • 0
    hi,

    it may be helpful for u

    textBox3.Text = Convert.ToString(Convert.ToInt16(textBox1.Text) + Convert.ToInt16(textBox2.Text));
    0