![](https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg60yJy8VdZPYO0RCvAabsF2njWwrTB3bZu2lH__91FUg49IimyIqKwMpYYv4Dpco_5WjWdlfWLdtm6pelvyBh3esHgHyYvdU8ee9KJ4UfWdHHpCK87npUig88r7IeG6jz_iiomQGe44qOA/s320/MENU.jpg)
Private Sub CommandButton1_Click()
If ComboBox1.ListIndex = 0 Then
TextBox3 = Val(TextBox1) + Val(TextBox2)
Else
If ComboBox1.ListIndex = 1 Then
TextBox3 = Val(TextBox1) - Val(TextBox2)
Else
If ComboBox1.ListIndex = 2 Then
TextBox3 = Val(TextBox1) * Val(TextBox2)
Else
If ComboBox1.ListIndex = 3 Then
TextBox3 = Val(TextBox1) / Val(TextBox2)
Else
If ComboBox1.ListIndex = 4 Then
TextBox3 = Val(TextBox1) ^ Val(TextBox2)
End If
End If
End If
End If
End If
ListBox1.AddItem TextBox3
End Sub
Private Sub CommandButton2_Click()
End
End Sub
Private Sub CommandButton3_Click()
TextBox1 = ""
TextBox2 = ""
TextBox3 = ""
End Sub
Private Sub CommandButton4_Click()
If ListBox1.ListIndex = 0 Then
ListBox1.RemoveItem 0
Else
If ListBox1.ListIndex = 1 Then
ListBox1.RemoveItem 1
Else
If ListBox1.ListIndex = 2 Then
ListBox1.RemoveItem 2
Else
If ListBox1.ListIndex = 3 Then
ListBox1.RemoveItem 3
Else
ListBox1.RemoveItem 4
End If
End If
End If
End If
End Sub
Private Sub UserForm_Initialize()
ComboBox1.AddItem "SUMA"
ComboBox1.AddItem "RESTA"
ComboBox1.AddItem "MULTIPLICACION"
ComboBox1.AddItem "DIVISION"
ComboBox1.AddItem "POTENCIA"
End Sub