Você está na página 1de 1

private void btnSalir_Click(object sender, EventArgs e)

{
this.Close();
}

private void btnSumar_Click(object sender, EventArgs e)


{
int total;
total = int.Parse(txtNumero1.Text) + int.Parse(txtNumero2.Text);
txtResultado.Text = total.ToString();
}

private void btnRestar_Click(object sender, EventArgs e)


{
int total;
total = int.Parse(txtNumero1.Text) - int.Parse(txtNumero2.Text);
txtResultado.Text = total.ToString();
}

private void btnMultiplicar_Click(object sender, EventArgs e)


{
int total;
total = int.Parse(txtNumero1.Text) * int.Parse(txtNumero2.Text);
txtResultado.Text = total.ToString();
}

private void btnDividir_Click(object sender, EventArgs e)


{
int total;
total = int.Parse(txtNumero1.Text) / int.Parse(txtNumero2.Text);
txtResultado.Text = total.ToString();
}

private void btnLimpiar_Click(object sender, EventArgs e)


{
txtNumero1.Text = "";
txtNumero2.Text = "";
txtResultado.Text = "";
txtNumero1.Focus();
}

private void txtNumero1_TextChanged(object sender, EventArgs e)


{

Você também pode gostar