vb
Private Sub Command1_Click() Dim a As Double, b As Double, c As Double, d As Double, e As Double a = Val(Text1.Text) b = Val(Text2.Text) c = Val(Text3.Text) d = Val(Text4.Text) e = Val(Text5.Text) If a > 20 Then MsgBox ("En practica debe ser menor o igual a 20") Else If b > 20 Then MsgBox ("Parcial debe ser menor o igual a 20") Else If c > 10 Then MsgBox ("Asistencia debe ser menor o igual a 10") Else If d > 50 Then MsgBox ("La nota del examén final debe ser menor que o igual a 50") Else Text5.Text = a + b + c + d + e End If End Sub