miércoles, 19 de noviembre de 2008

Ascensor final (por alan)

Private Sub Label2_Click()
Asensor.Top = 4560
End Sub

Private Sub Label7_Click()

End Sub

Private Sub Label1_Click()

End Sub

Private Sub Enter_Click()
If Contraseña.Text = jamon Then
Asensor.Top = 240
End If
End Sub

Private Sub L1_Click()
auxiliar.Caption = Asensor.Top
Asensor.Top = 3120
L1.Enabled = False
L2.Enabled = True
L3.Enabled = True
L4.Enabled = True
L5.Enabled = True
LSS.Enabled = True
LPB.Enabled = True
Llamar1.Enabled = False
Llamar2.Enabled = True
Llamar3.Enabled = True
Llamar4.Enabled = True
Llamar5.Enabled = True
LlamarSS.Enabled = True
LlamarPB.Enabled = True
Contraseña.Text = ""
If Asensor.Top = 3120 Then
P5.Caption = "1"
P4.Caption = "1"
P3.Caption = "1"
P2.Caption = "1"
P1.Caption = "1"
PSS.Caption = "1"
PPB.Caption = "1"
PT.Caption = "1"
End If
If Asensor.Top = 3120 Then
contador1.Caption = contador1.Caption + 1
End If
total.Caption = Val(total.Caption) + ((Abs(Val(auxiliar.Caption) - Asensor.Top)) / 720)
End Sub

Private Sub L2_Click()
auxiliar.Caption = Asensor.Top
Asensor.Top = 2400
L1.Enabled = True
L2.Enabled = False
L3.Enabled = True
L4.Enabled = True
L5.Enabled = True
LSS.Enabled = True
LPB.Enabled = True
Llamar1.Enabled = True
Llamar2.Enabled = False
Llamar3.Enabled = True
Llamar4.Enabled = True
Llamar5.Enabled = True
LlamarSS.Enabled = True
LlamarPB.Enabled = True
Contraseña.Text = ""
If Asensor.Top = 2400 Then
P5.Caption = "2"
P4.Caption = "2"
P3.Caption = "2"
P2.Caption = "2"
P1.Caption = "2"
PSS.Caption = "2"
PPB.Caption = "2"
PT.Caption = "2"
End If
If Asensor.Top = 2400 Then
contador2.Caption = contador2.Caption + 1
End If
total.Caption = Val(total.Caption) + ((Abs(Val(auxiliar.Caption) - Asensor.Top)) / 720)
End Sub

Private Sub L3_Click()
auxiliar.Caption = Asensor.Top
Asensor.Top = 1680
L1.Enabled = True
L2.Enabled = True
L3.Enabled = False
L4.Enabled = True
L5.Enabled = True
LSS.Enabled = True
LPB.Enabled = True
Llamar1.Enabled = True
Llamar2.Enabled = True
Llamar3.Enabled = False
Llamar4.Enabled = True
Llamar5.Enabled = True
LlamarSS.Enabled = True
LlamarPB.Enabled = True
Contraseña.Text = ""
If Asensor.Top = 1680 Then
P5.Caption = "3"
P4.Caption = "3"
P3.Caption = "3"
P2.Caption = "3"
P1.Caption = "3"
PSS.Caption = "3"
PPB.Caption = "3"
PT.Caption = "3"
End If
If Asensor.Top = 1680 Then
contador3.Caption = contador3.Caption + 1
End If
total.Caption = Val(total.Caption) + ((Abs(Val(auxiliar.Caption) - Asensor.Top)) / 720)
End Sub

Private Sub L4_Click()
auxiliar.Caption = Asensor.Top
0 Asensor.Top = 960
L1.Enabled = True
L2.Enabled = True
L3.Enabled = True
L4.Enabled = False
L5.Enabled = True
LSS.Enabled = True
LPB.Enabled = True
Llamar1.Enabled = True
Llamar2.Enabled = True
Llamar3.Enabled = True
Llamar4.Enabled = False
Llamar5.Enabled = True
LlamarSS.Enabled = True
LlamarPB.Enabled = True
Contraseña.Text = ""
If Asensor.Top = 960 Then
P5.Caption = "4"
P4.Caption = "4"
P3.Caption = "4"
P2.Caption = "4"
P1.Caption = "4"
PSS.Caption = "4"
PPB.Caption = "4"
PT.Caption = "4"
End If
If Asensor.Top = 960 Then
contador4.Caption = contador4.Caption + 1
End If
total.Caption = Val(total.Caption) + ((Abs(Val(auxiliar.Caption) - Asensor.Top)) / 720)
End Sub

Private Sub L5_Click()
auxiliar.Caption = Asensor.Top
If Contraseña.Text = "Honda" Then
Asensor.Top = 240
End If
L1.Enabled = True
L2.Enabled = True
L3.Enabled = True
L4.Enabled = True
L5.Enabled = True
LSS.Enabled = True
LPB.Enabled = True
Llamar1.Enabled = True
Llamar2.Enabled = True
Llamar3.Enabled = True
Llamar4.Enabled = True
Llamar5.Enabled = False
LlamarSS.Enabled = True
LlamarPB.Enabled = True
Contraseña.Text = ""
If Asensor.Top = 240 Then
L5.Enabled = False
End If
If Asensor.Top = 240 Then
P5.Caption = "5"
P4.Caption = "5"
P3.Caption = "5"
P2.Caption = "5"
P1.Caption = "5"
PSS.Caption = "5"
PPB.Caption = "5"
PT.Caption = "5"
End If
If Asensor.Top = 240 Then
contador5.Caption = contador5.Caption + 1
End If
total.Caption = Val(total.Caption) + ((Abs(Val(auxiliar.Caption) - Asensor.Top)) / 720)
End Sub


Private Sub Llamar1_Click()
auxiliar.Caption = Asensor.Top
Asensor.Top = 3120
L1.Enabled = False
L2.Enabled = True
L3.Enabled = True
L4.Enabled = True
L5.Enabled = True
LSS.Enabled = True
LPB.Enabled = True
Llamar1.Enabled = False
Llamar2.Enabled = True
Llamar3.Enabled = True
Llamar4.Enabled = True
Llamar5.Enabled = True
LlamarSS.Enabled = True
LlamarPB.Enabled = True
Contraseña.Text = ""
If Asensor.Top = 3120 Then
P5.Caption = "1"
P4.Caption = "1"
P3.Caption = "1"
P2.Caption = "1"
P1.Caption = "1"
PSS.Caption = "1"
PPB.Caption = "1"
PT.Caption = "1"
End If
If Asensor.Top = 3120 Then
contador1.Caption = contador1.Caption + 1
End If
total.Caption = Val(total.Caption) + ((Abs(Val(auxiliar.Caption) - Asensor.Top)) / 720)
End Sub

Private Sub Llamar2_Click()
auxiliar.Caption = Asensor.Top
Asensor.Top = 2400
L1.Enabled = True
L2.Enabled = False
L3.Enabled = True
L4.Enabled = True
L5.Enabled = True
LSS.Enabled = True
LPB.Enabled = True
Llamar1.Enabled = True
Llamar2.Enabled = False
Llamar3.Enabled = True
Llamar4.Enabled = True
Llamar5.Enabled = True
LlamarSS.Enabled = True
LlamarPB.Enabled = True
Contraseña.Text = ""
If Asensor.Top = 2400 Then
P5.Caption = "2"
P4.Caption = "2"
P3.Caption = "2"
P2.Caption = "2"
P1.Caption = "2"
PSS.Caption = "2"
PPB.Caption = "2"
PT.Caption = "2"
End If
If Asensor.Top = 2400 Then
contador2.Caption = contador2.Caption + 1
End If
total.Caption = Val(total.Caption) + ((Abs(Val(auxiliar.Caption) - Asensor.Top)) / 720)
End Sub

Private Sub Llamar3_Click()
auxiliar.Caption = Asensor.Top
Asensor.Top = 1680
L1.Enabled = True
L2.Enabled = True
L3.Enabled = False
L4.Enabled = True
L5.Enabled = True
LSS.Enabled = True
LPB.Enabled = True
Llamar1.Enabled = True
Llamar2.Enabled = True
Llamar3.Enabled = False
Llamar4.Enabled = True
Llamar5.Enabled = True
LlamarSS.Enabled = True
LlamarPB.Enabled = True
Contraseña.Text = ""
If Asensor.Top = 1680 Then
P5.Caption = "3"
P4.Caption = "3"
P3.Caption = "3"
P2.Caption = "3"
P1.Caption = "3"
PSS.Caption = "3"
PPB.Caption = "3"
PT.Caption = "3"
End If
If Asensor.Top = 1680 Then
contador3.Caption = contador3.Caption + 1
End If
total.Caption = Val(total.Caption) + ((Abs(Val(auxiliar.Caption) - Asensor.Top)) / 720)
End Sub

Private Sub Llamar4_Click()
auxiliar.Caption = Asensor.Top
Asensor.Top = 960
L1.Enabled = True
L2.Enabled = True
L3.Enabled = True
L4.Enabled = False
L5.Enabled = True
LSS.Enabled = True
LPB.Enabled = True
Llamar1.Enabled = True
Llamar2.Enabled = True
Llamar3.Enabled = True
Llamar4.Enabled = False
Llamar5.Enabled = True
LlamarSS.Enabled = True
LlamarPB.Enabled = True
Contraseña.Text = ""
If Asensor.Top = 960 Then
P5.Caption = "4"
P4.Caption = "4"
P3.Caption = "4"
P2.Caption = "4"
P1.Caption = "4"
PSS.Caption = "4"
PPB.Caption = "4"
PT.Caption = "4"
End If
total.Caption = Val(total.Caption) + ((Abs(Val(auxiliar.Caption) - Asensor.Top)) / 720)
End Sub

Private Sub Llamar5_Click()
auxiliar.Caption = Asensor.Top
Asensor.Top = 240
L1.Enabled = True
L2.Enabled = True
L3.Enabled = True
L4.Enabled = True
L5.Enabled = True
LSS.Enabled = True
LPB.Enabled = True
Llamar1.Enabled = True
Llamar2.Enabled = True
Llamar3.Enabled = True
Llamar4.Enabled = True
Llamar5.Enabled = False
LlamarSS.Enabled = True
LlamarPB.Enabled = True
Contraseña.Text = ""
If Asensor.Top = 240 Then
P5.Caption = "5"
P4.Caption = "5"
P3.Caption = "5"
P2.Caption = "5"
P1.Caption = "5"
PSS.Caption = "5"
PPB.Caption = "5"
PT.Caption = "5"
End If
total.Caption = Val(total.Caption) + ((Abs(Val(auxiliar.Caption) - Asensor.Top)) / 720)
End Sub

Private Sub LlamarPB_Click()
auxiliar.Caption = Asensor.Top
Asensor.Top = 3840
L1.Enabled = True
L2.Enabled = True
L3.Enabled = True
L4.Enabled = True
L5.Enabled = True
LSS.Enabled = True
LPB.Enabled = False
Llamar1.Enabled = True
Llamar2.Enabled = True
Llamar3.Enabled = True
Llamar4.Enabled = True
Llamar5.Enabled = True
LlamarSS.Enabled = True
LlamarPB.Enabled = False
Contraseña.Text = ""
If Asensor.Top = 3840 Then
P5.Caption = "PB"
P4.Caption = "PB"
P3.Caption = "PB"
P2.Caption = "PB"
P1.Caption = "PB"
PSS.Caption = "PB"
PPB.Caption = "PB"
PT.Caption = "PB"
End If
If Asensor.Top = 3840 Then
contadorPB.Caption = contadorPB.Caption + 1
End If
total.Caption = Val(total.Caption) + ((Abs(Val(auxiliar.Caption) - Asensor.Top)) / 720)
End Sub

Private Sub LlamarSS_Click()
auxiliar.Caption = Asensor.Top
Asensor.Top = 4560
Asensor.Top = 4560
L1.Enabled = True
L2.Enabled = True
L3.Enabled = True
L4.Enabled = True
L5.Enabled = True
LSS.Enabled = False
LPB.Enabled = True
Llamar1.Enabled = True
Llamar2.Enabled = True
Llamar3.Enabled = True
Llamar4.Enabled = True
Llamar5.Enabled = True
LlamarSS.Enabled = False
LlamarPB.Enabled = True
Contraseña.Text = ""
If Asensor.Top = 4560 Then
P5.Caption = "SS"
P4.Caption = "SS"
P3.Caption = "SS"
P2.Caption = "SS"
P1.Caption = "SS"
PSS.Caption = "SS"
PPB.Caption = "SS"
PT.Caption = "SS"
End If
If Asensor.Top = 4560 Then
contadorSS.Caption = contadorSS.Caption + 1
End If
total.Caption = Val(total.Caption) + ((Abs(Val(auxiliar.Caption) - Asensor.Top)) / 720)
End Sub

Private Sub LPB_Click()
auxiliar.Caption = Asensor.Top
Asensor.Top = 3840
L1.Enabled = True
L2.Enabled = True
L3.Enabled = True
L4.Enabled = True
L5.Enabled = True
LSS.Enabled = True
LPB.Enabled = False
Llamar1.Enabled = True
Llamar2.Enabled = True
Llamar3.Enabled = True
Llamar4.Enabled = True
Llamar5.Enabled = True
LlamarSS.Enabled = True
LlamarPB.Enabled = False
Contraseña.Text = ""
If Asensor.Top = 3840 Then
P5.Caption = "PB"
P4.Caption = "PB"
P3.Caption = "PB"
P2.Caption = "PB"
P1.Caption = "PB"
PSS.Caption = "PB"
PPB.Caption = "PB"
PT.Caption = "PB"
End If
If Asensor.Top = 3840 Then
contadorPB.Caption = contadorPB.Caption + 1
End If
total.Caption = Val(total.Caption) + ((Abs(Val(auxiliar.Caption) - Asensor.Top)) / 720)
End Sub

Private Sub LSS_Click()
auxiliar.Caption = Asensor.Top
Asensor.Top = 4560
L1.Enabled = True
L2.Enabled = True
L3.Enabled = True
L4.Enabled = True
L5.Enabled = True
LSS.Enabled = False
LPB.Enabled = True
Llamar1.Enabled = True
Llamar2.Enabled = True
Llamar3.Enabled = True
Llamar4.Enabled = True
Llamar5.Enabled = True
LlamarSS.Enabled = False
LlamarPB.Enabled = True
Contraseña.Text = ""
If Asensor.Top = 4560 Then
P5.Caption = "SS"
P4.Caption = "SS"
P3.Caption = "SS"
P2.Caption = "SS"
P1.Caption = "SS"
PSS.Caption = "SS"
PPB.Caption = "SS"
PT.Caption = "SS"
PT.Caption = "SS"
End If
If Asensor.Top = 4560 Then
contadorSS.Caption = contadorSS.Caption + 1
End If
total.Caption = Val(total.Caption) + ((Abs(Val(auxiliar.Caption) - Asensor.Top)) / 720)
End Sub

Private Sub luz_Click()
If Asensor.BackColor = vbYellow Then
Asensor.BackColor = vbBlack
Else
Asensor.BackColor = vbYellow
End If
End Sub

Private Sub stop_Click()
If Llamar1.Enabled = True Then
Llamar1.Enabled = False
Llamar2.Enabled = False
Llamar3.Enabled = False
Llamar4.Enabled = False
Llamar5.Enabled = False
LlamarPB.Enabled = False
LlamarSS.Enabled = False
L1.Enabled = False
L2.Enabled = False
L3.Enabled = False
L4.Enabled = False
L5.Enabled = False
LSS.Enabled = False
LPB.Enabled = False
luz.Enabled = False
Else
Llamar1.Enabled = True
Llamar2.Enabled = True
Llamar3.Enabled = True
Llamar4.Enabled = True
Llamar5.Enabled = True
LlamarPB.Enabled = True
LlamarSS.Enabled = True
L1.Enabled = True
L2.Enabled = True
L3.Enabled = True
L4.Enabled = True
L5.Enabled = True
LSS.Enabled = True
LPB.Enabled = True
luz.Enabled = True
End If
Contraseña.Text = ""
End Sub

No hay comentarios: