Error 13 en tiempo de ejecucion, los tipos
Publicado por Mariany (2 intervenciones) el 31/10/2011 15:17:24
Buenas, tengo un problema con este error, que me sale en la primera linea de codigo de este que ahora que les presentare, la verdad no se como resolverlo, y tampoco que lo causa, si me podrian ayudar le agradeceria.
es un programa que calcula el resultado de pruebas ecritas, y este codigo se supone calcula las respues PC, o Baremos de las respuestas de las personas.
If Text1(9).Text > 22 Then
Text1(1).Text = 99
ElseIf Text1(9).Text = 22 Then
Text1(1).Text = 98
ElseIf Text1(9).Text = 21 Then
Text1(1).Text = 97
ElseIf Text1(9).Text = 20 Then
Text1(1).Text = 96
ElseIf Text1(9).Text = 19 Then
Text1(1).Text = 95
ElseIf Text1(9).Text > 16 And Text1(9).Text < 19 Then
Text1(1).Text = 90
ElseIf Text1(9).Text = 16 Then
Text1(1).Text = 85
ElseIf Text1(9).Text = 15 Then
Text1(1).Text = 75
ElseIf Text1(9).Text = 14 Then
Text1(1).Text = 70
ElseIf Text1(9).Text = 13 Then
Text1(1).Text = 65
ElseIf Text1(9).Text = 12 Then
Text1(1).Text = 55
ElseIf Text1(9).Text = 11 Then
Text1(1).Text = 45
ElseIf Text1(9).Text = 10 Then
Text1(1).Text = 40
ElseIf Text1(9).Text = 9 Then
Text1(1).Text = 35
ElseIf Text1(9).Text = 8 Then
Text1(1).Text = 30
ElseIf Text1(9).Text = 7 Then
Text1(1).Text = 25
ElseIf Text1(9).Text = 6 Then
Text1(1).Text = 15
ElseIf Text1(9).Text = 5 Then
Text1(1).Text = 10
ElseIf Text1(9).Text = 4 Then
Text1(1).Text = 5
ElseIf Text1(9).Text = 3 Then
Text1(1).Text = 3
ElseIf Text1(9).Text < 3 Then
Text1(1).Text = 1
End If
'***********************************
'PC VR+NR
'***********************************
With Text1(15)
If .Text > 48 Then
Text1(7).Text = 99
ElseIf .Text > 46 And .Text < 48 Then
Text1(7).Text = 98
ElseIf .Text = 46 Then
Text1(7).Text = 97
ElseIf .Text > 43 And .Text < 46 Then
Text1(7).Text = 96
ElseIf .Text = 43 Then
Text1(7).Text = 95
ElseIf .Text > 36 And .Text < 43 Then
Text1(7).Text = 90
ElseIf .Text > 34 And .Text < 37 Then
Text1(7).Text = 85
ElseIf .Text = 34 Then
Text1(7).Text = 80
ElseIf .Text = 33 Then
Text1(7).Text = 75
ElseIf .Text > 30 And .Text < 33 Then
Text1(7).Text = 70
ElseIf .Text = 30 Then
Text1(7).Text = 65
ElseIf .Text > 27 And .Text < 30 Then
Text1(7).Text = 60
ElseIf .Text = 27 Then
Text1(7).Text = 55
ElseIf .Text = 26 Then
Text1(7).Text = 45
ElseIf .Text > 23 And .Text < 26 Then
Text1(7).Text = 40
ElseIf .Text = 23 Then
Text1(7).Text = 30
ElseIf .Text > 19 And .Text < 23 Then
Text1(7).Text = 25
ElseIf .Text > 17 And .Text < 20 Then
Text1(7).Text = 20
ElseIf .Text = 17 Then
Text1(7).Text = 15
ElseIf .Text > 14 And .Text < 17 Then
Text1(7).Text = 10
ElseIf .Text > 10 And .Text < 15 Then
Text1(7).Text = 5
ElseIf .Text = 10 Then
Text1(7).Text = 3
ElseIf .Text > 7 And .Text < 10 Then
Text1(7).Text = 2
ElseIf .Text < 8 Then
Text1(7).Text = 1
End If
End With
es un programa que calcula el resultado de pruebas ecritas, y este codigo se supone calcula las respues PC, o Baremos de las respuestas de las personas.
If Text1(9).Text > 22 Then
Text1(1).Text = 99
ElseIf Text1(9).Text = 22 Then
Text1(1).Text = 98
ElseIf Text1(9).Text = 21 Then
Text1(1).Text = 97
ElseIf Text1(9).Text = 20 Then
Text1(1).Text = 96
ElseIf Text1(9).Text = 19 Then
Text1(1).Text = 95
ElseIf Text1(9).Text > 16 And Text1(9).Text < 19 Then
Text1(1).Text = 90
ElseIf Text1(9).Text = 16 Then
Text1(1).Text = 85
ElseIf Text1(9).Text = 15 Then
Text1(1).Text = 75
ElseIf Text1(9).Text = 14 Then
Text1(1).Text = 70
ElseIf Text1(9).Text = 13 Then
Text1(1).Text = 65
ElseIf Text1(9).Text = 12 Then
Text1(1).Text = 55
ElseIf Text1(9).Text = 11 Then
Text1(1).Text = 45
ElseIf Text1(9).Text = 10 Then
Text1(1).Text = 40
ElseIf Text1(9).Text = 9 Then
Text1(1).Text = 35
ElseIf Text1(9).Text = 8 Then
Text1(1).Text = 30
ElseIf Text1(9).Text = 7 Then
Text1(1).Text = 25
ElseIf Text1(9).Text = 6 Then
Text1(1).Text = 15
ElseIf Text1(9).Text = 5 Then
Text1(1).Text = 10
ElseIf Text1(9).Text = 4 Then
Text1(1).Text = 5
ElseIf Text1(9).Text = 3 Then
Text1(1).Text = 3
ElseIf Text1(9).Text < 3 Then
Text1(1).Text = 1
End If
'***********************************
'PC VR+NR
'***********************************
With Text1(15)
If .Text > 48 Then
Text1(7).Text = 99
ElseIf .Text > 46 And .Text < 48 Then
Text1(7).Text = 98
ElseIf .Text = 46 Then
Text1(7).Text = 97
ElseIf .Text > 43 And .Text < 46 Then
Text1(7).Text = 96
ElseIf .Text = 43 Then
Text1(7).Text = 95
ElseIf .Text > 36 And .Text < 43 Then
Text1(7).Text = 90
ElseIf .Text > 34 And .Text < 37 Then
Text1(7).Text = 85
ElseIf .Text = 34 Then
Text1(7).Text = 80
ElseIf .Text = 33 Then
Text1(7).Text = 75
ElseIf .Text > 30 And .Text < 33 Then
Text1(7).Text = 70
ElseIf .Text = 30 Then
Text1(7).Text = 65
ElseIf .Text > 27 And .Text < 30 Then
Text1(7).Text = 60
ElseIf .Text = 27 Then
Text1(7).Text = 55
ElseIf .Text = 26 Then
Text1(7).Text = 45
ElseIf .Text > 23 And .Text < 26 Then
Text1(7).Text = 40
ElseIf .Text = 23 Then
Text1(7).Text = 30
ElseIf .Text > 19 And .Text < 23 Then
Text1(7).Text = 25
ElseIf .Text > 17 And .Text < 20 Then
Text1(7).Text = 20
ElseIf .Text = 17 Then
Text1(7).Text = 15
ElseIf .Text > 14 And .Text < 17 Then
Text1(7).Text = 10
ElseIf .Text > 10 And .Text < 15 Then
Text1(7).Text = 5
ElseIf .Text = 10 Then
Text1(7).Text = 3
ElseIf .Text > 7 And .Text < 10 Then
Text1(7).Text = 2
ElseIf .Text < 8 Then
Text1(7).Text = 1
End If
End With
Valora esta pregunta


0