I have problem With My Calculator in ASP.NET C# in Microsoft Visual Web Developer 2008 Express Edition : web application not windows application

the code:

protected void Button2_Click(object sender, EventArgs e)
{

//Double F1;
//Double S1;
// Double Re;
// F1 = Convert.ToDouble(TextBox1.Text);
// S1 = Convert.ToDouble(TextBox2.Text);
// Re = F1 - S1;
// Label1.Text = Convert.ToString(Re);

}

how to make it works with one text box ?

it means one box take the first number then operation -+*/ then the second number , final the result after i click the = button

thnx

Katherine87, i haven't understood what you have said..You mean entering 2 values in a single text box and printing the result in a label..

Katherine87, i haven't understood what you have said..You mean entering 2 values in a single text box and printing the result in a label..

No, it must be work as windows calculator one text box for both two numbers;

like example;

enter first value 1 in that text box then click -+/ the value will be stored in variable, after that you will see nothening in text box then you entered the second value 2, after you clicked = you will see the result 3 just

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.