Código:
Hasta ahi me evalua lo de maternal, y todo bien, hace los descuentos y todo, pero cuando quiero agregar el if para evaluar lo de primaria uso esto: Private Sub Text7_Click()
Dim num1 As Double
Dim porcentaje As Double
If Combo1.Text = "Maternal" Then
num1 = "1250"
If Combo3.Text = "Quincenal" Then
num1 = num1 / 2
Text7 = num1
If Combo5.Text = "25%" Then
porcentaje = num1 * 0.25
num1 = num1 - porcentaje
Text7 = num1
Else: Combo5.Text = "50%"
porcentaje = num1 * 0.5
num1 = num1 - porcentaje
Text7 = num1
End If
Else: Combo3.Text = "Mensual"
num1 = num1
Text7 = num1
If Combo5.Text = "25%" Then
porcentaje = num1 * 0.25
num1 = num1 - porcentaje
Text7 = num1
Else: Combo5.Text = "50%"
porcentaje = num1 * 0.5
num1 = num1 - porcentaje
Text7 = num1
End If
End If
End If
End Sub
Código:
Private Sub Text7_Click()
Dim num1 As Double
Dim porcentaje As Double
If Combo1.Text = "Maternal" Then
num1 = "1250"
If Combo3.Text = "Quincenal" Then
num1 = num1 / 2
Text7 = num1
If Combo5.Text = "25%" Then
porcentaje = num1 * 0.25
num1 = num1 - porcentaje
Text7 = num1
Else: Combo5.Text = "50%"
porcentaje = num1 * 0.5
num1 = num1 - porcentaje
Text7 = num1
End If
Else: Combo3.Text = "Mensual"
num1 = num1
Text7 = num1
If Combo5.Text = "25%" Then
porcentaje = num1 * 0.25
num1 = num1 - porcentaje
Text7 = num1
Else: Combo5.Text = "50%"
porcentaje = num1 * 0.5
num1 = num1 - porcentaje
Text7 = num1
End If
Else: Combo1.Text = "Preescolar"
num1 = "1350"
If Combo3.Text = "Quincenal" Then
num1 = num1 / 2
Text7 = num1
If Combo5.Text = "25%" Then
porcentaje = num1 * 0.25
num1 = num1 - porcentaje
Text7 = num1
Else: Combo5.Text = "50%"
porcentaje = num1 * 0.5
num1 = num1 - porcentaje
Text7 = num1
End If
Else: Combo3.Text = "Mensual"
num1 = num1
Text7 = num1
If Combo5.Text = "25%" Then
porcentaje = num1 * 0.25
num1 = num1 - porcentaje
Text7 = num1
Else: Combo5.Text = "50%"
porcentaje = num1 * 0.5
num1 = num1 - porcentaje
Text7 = num1
End If
End If
End If
End If
End Sub
y ahì me sale un error de end sin if , me podrian revisar el còdigo por favor? gracias de antemano.


