Anda di halaman 1dari 11

CALCULADORA

VIS UAL B AS IC 6. 0

TEACHER EDWIN
CACERES

Crearemos un programa donde introduciendo 2 nmeros nos calcule


la suma y resta de ambos nmeros, pudiendo borrar los
valores introducidos mediante otro botn y salir de la aplicacin.

BOTON
SUMA

BOTON
RESTA
BOTON
MULTIPLICA
R
BOTON
SALIR

BOTON
BORRAR

Private Sub Command1_Click()


Text3.Text = Val(Text1.Text) + Val(Text2.Text)
End Sub
Private Sub Command2_Click()
Text3.Text = Val(Text1.Text) - Val(Text2.Text)
End Sub
Private Sub Command3_Click()
Text3.Text = Val(Text1.Text) * Val(Text2.Text)
End Sub
Private Sub Command5_Click()
End
End Sub
Private Sub Command6_Click()
Text1.Text = ""
Text2.Text = ""
Text3.Text = ""
Text1.SetFocus
End Sub

Anda mungkin juga menyukai