v blackcaps

v blackcaps

  • 1.9k
  • 27
  • 1.4k

adding two numbers and how to solve this problem?

Jan 14 2020 5:47 PM
I try to write a code adding two numbers using text box it show sum error plz helop me.
int num1;
            int num2;
            int total;

        private void button1_Click(object sender, EventArgs e)
            // this program calculate 2 numbers and display the result in the message box
            int num1 = Convert.ToInt32(textBox1.Text);
            int num2 = Convert.ToInt32(textBox2.Text);
            int total = num1 + num2;

Brought to you by: JavaScript SDK for Bold BI dashboard and analytics embedding. Free trial.

Answers (2)