Form1 Object Eventargs: "Masculino"

Download as pdf or txt
Download as pdf or txt
You are on page 1of 3

Programa en visual para calcular un promedio, y decir si la persona es SR. SRA.

SRITA. O Joven

Public Class Form1


Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles Button1.Click
Dim vec = {TextBox6, TextBox7, TextBox8}
Dim vector(3), j, acum As Integer
For j = 0 To 2
vector(j) = vec(j).Text
Next
For j = 0 To 2
acum = acum + vector(j)
Next
TextBox10.Text = acum / 3
TextBox9.Text = acum / 3

If (TextBox4.Text < 18) And (TextBox5.Text = "masculino") Then


Label17.Visible = True
End If
If (TextBox4.Text > 18) And (TextBox5.Text = "masculino") Then
Label14.Visible = True
End If

If (TextBox4.Text < 18) And (TextBox5.Text = "femenino") Then


Label16.Visible = True
End If
If (TextBox4.Text > 18) And (TextBox5.Text = "femenino") Then
Label15.Visible = True
End If
If (TextBox9.Text > 7) Then
Label18.Visible = True
End If
If (TextBox10.Text < 6) Then
Label19.Visible = True
End If
End Sub

Private Sub Label10_Click(ByVal sender As System.Object, ByVal e As


System.EventArgs) Handles Label10.Click

End Sub

Private Sub Label9_Click(ByVal sender As System.Object, ByVal e As


System.EventArgs) Handles Label9.Click

End Sub

Private Sub Label8_Click(ByVal sender As System.Object, ByVal e As


System.EventArgs) Handles Label8.Click

End Sub

Private Sub Label7_Click(ByVal sender As System.Object, ByVal e As


System.EventArgs) Handles Label7.Click

End Sub
Private Sub Label6_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles Label6.Click

End Sub

Private Sub Label4_Click(ByVal sender As System.Object, ByVal e As


System.EventArgs) Handles Label4.Click

End Sub

Private Sub Label5_Click(ByVal sender As System.Object, ByVal e As


System.EventArgs) Handles Label5.Click

End Sub

Private Sub Label3_Click(ByVal sender As System.Object, ByVal e As


System.EventArgs) Handles Label3.Click

End Sub

Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As


System.EventArgs) Handles MyBase.Load
Label17.Visible = False
Label16.Visible = False
Label15.Visible = False
Label14.Visible = False
Label18.Visible = False
Label19.Visible = False

End Sub

Private Sub Label17_Click(ByVal sender As System.Object, ByVal e As


System.EventArgs) Handles Label17.Click

End Sub
End Class

You might also like