Hola a todos, mi problemas es el siguiente, tengo un programa echo en excel, el cual ya me caduco y por lo tanto ya no puedo usarlo, pero me di cuebta que modificando el codigo vba puedo dejarlo sin que caduque, ya le e busque modificar pero no logro acerlo andar.
acontinuacion pego el codigo, espero alguien me pueda ayudar. gracias.
Private Sub reducciones_Click()
On Error GoTo Tratar_Errores
Dim referencia As Range
Dim referencia2, referprint As String
Dim ref2, ref4 As Integer
Dim pass, pass2 As Variant
MsgBox Prompt:="ESTE SOFTWARE ES UNA VERSIÓN DE DEMOSTRACIÓN. " & Chr(13) & "" & Chr(13) & "COMPRE LA LICENCIA.", Title:="loto"
pass = "21565"
Range("EP1").Select
If ActiveCell.Value = "" Then
ActiveCell.Formula = "=CONCATENATE(INFO(""directorio""),INFO(""version""),INFO(""versionso""))"
Selection.Copy
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
:=False, Transpose:=False
Application.CutCopyMode = False
Range("C1").Select
ActiveWorkbook.Save
Else
Range("EQ1").Select
ActiveCell.Formula = "=CONCATENATE(INFO(""directorio""),INFO(""version""),INFO(""versionso""))"
Selection.Copy
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
:=False, Transpose:=False
Application.CutCopyMode = False
If ActiveCell.Value <> ActiveCell.Offset(0, -1).Value Then
Range("C1").Select
MsgBox Prompt:="EL SOFTWARE NO FUNCIONARÁ CORRECTAMENTE PORQUE YA HA SIDO DESCARGADO EN OTRA COMPUTADORA O EN OTRO DIRECTORIO." & Chr(13) & "" & Chr(13) & "ASEGÚRESE DE HABER EJECUTADO EL SOFTWARE DONDE USTED LO SALVÓ LA PRIMERA VEZ." & Chr(13) & "" & Chr(13) & "SI USTED BORRÓ ESE ARCHIVO NECESITARÁ COMPRAR ESTE SOFTWARE OTRA VEZ PARA QUE FUNCIONE CON ESTA COMPUTADORA Y ESTE SISTEMA OPERATIVO.", Title:="loto"
Exit Sub
End If
End If
Range("ES2").Select
If ActiveCell.Value <> "" Then
Range("C1").Select
MsgBox Prompt:="EL TIEMPO DEL SOFTWARE DE DEMOSTRACIÓN HA EXPIRADO. " & Chr(13) & "" & Chr(13) & "COMPRE LA LICENCIA.", Title:="loto"
Exit Sub
Else
If Dir("C:system.txt") = "system.txt" Then
Workbooks.OpenText Filename:="C:system.txt", Origin:=xlWindows, StartRow _
:=1, DataType:=xlDelimited, TextQualifier:=xlDoubleQuote, _
ConsecutiveDelimiter:=False, Tab:=True, Semicolon:=False, Comma:=False _
, Space:=False, Other:=False, FieldInfo:=Array(1, 1), _
TrailingMinusNumbers:=True
ActiveWindow.WindowState = xlNormal
With ActiveWindow
.Top = 376.75
.Left = 658
End With
With ActiveWindow
.Width = 102
.Height = 64.5
End With
ActiveCell.Select
pass2 = ActiveCell.Value
ActiveWindow.Close SaveChanges:=False
ActiveWindow.WindowState = xlMaximized
If pass = pass2 Then
Range("C1").Select
MsgBox Prompt:="EL TIEMPO DEL SOFTWARE DE DEMOSTRACIÓN HA EXPIRADO. " & Chr(13) & "" & Chr(13) & "COMPRE LA LICENCIA.", Title:="loto"
Exit Sub
End If
End If
End If
Range("EP2").Select
If ActiveCell.Value = "" Then
ActiveCell.Formula = "=NOW()"
Selection.Copy
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
:=False, Transpose:=False
Application.CutCopyMode = False
Range("C1").Select
ActiveWorkbook.Save
Else
Range("EQ2").Select
ActiveCell.Formula = "=NOW()"
Selection.Copy
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
:=False, Transpose:=False
Application.CutCopyMode = False
ActiveCell.Offset(0, 1).Range("A1").Select
ActiveCell.FormulaR1C1 = "=RC[-1]-RC[-2]"
'Aquí se cambia el plazo de vigencia del software
If ActiveCell.Value > 3 Then
ActiveCell.Offset(0, 1).Value = pass
If Dir("C:system.txt") = "system.txt" Then
Workbooks.OpenText Filename:="C:system.txt", Origin:=xlWindows, StartRow _
:=1, DataType:=xlDelimited, TextQualifier:=xlDoubleQuote, _
ConsecutiveDelimiter:=False, Tab:=True, Semicolon:=False, Comma:=False _
, Space:=False, Other:=False, FieldInfo:=Array(1, 1), _
TrailingMinusNumbers:=True
ActiveWindow.WindowState = xlNormal
With ActiveWindow
.Top = 376.75
.Left = 658
End With
With ActiveWindow
.Width = 102
.Height = 64.5
End With
ActiveCell.Value = pass
ActiveWindow.Close SaveChanges:=True
ActiveWindow.WindowState = xlMaximized
Else
Workbooks.Add
ActiveWindow.WindowState = xlNormal
With ActiveWindow
.Top = 376.75
.Left = 658
End With
With ActiveWindow
.Width = 102
.Height = 64.5
End With
ActiveCell.Value = pass
Selection.Font.ColorIndex = 2
ActiveWorkbook.SaveAs Filename:="C:system.txt", FileFormat:=xlUnicodeText _
, CreateBackup:=False
ActiveWindow.Close SaveChanges:=False
ActiveWindow.WindowState = xlMaximized
End If
Range("C1").Select
MsgBox Prompt:="EL TIEMPO DEL SOFTWARE DE DEMOSTRACIÓN HA EXPIRADO. " & Chr(13) & "" & Chr(13) & "COMPRE LA LICENCIA.", Title:="loto"
Exit Sub
End If
End If
If lista3.ListIndex = -1 Or lista2.ListIndex = -1 Or lista1.ListIndex = -1 Then
MsgBox Prompt:="ASEGÚRESE DE HABER ELEGIDO UN ELEMENTO DE LAS LISTAS PREVIAS, YA QUE DE OTRA FORMA EL SOFTWARE NO FUNCIONARÁ.", Title:="loto"
Range("C1").Select
Exit Sub
End If
Set referencia = ActiveSheet.Range("AA2002")
referencia2 = referencia.Value
Select Case referencia2
Case 310
Range("red310").Select
Case 312
Range("red312").Select
Case 314
Range("red314").Select
Case 315
Range("red315").Select
Case 316
Range("red316").Select
Case 317
Range("red317").Select
Case 318
Range("red318").Select
Case 320
Range("red320").Select
Case 37
Range("red37").Select
Case 39
Range("red39").Select
Case 410
Range("red410").Select
Case 411
Range("red411").Select
Case 412
Range("red412").Select
Case 415
Range("red415").Select
Case 418
Range("red418").Select
Case 421
Range("red421").Select
Case 424
Range("red424").Select
Case 425
Range("red425").Select
Case 427
Range("red427").Select
Case 430
Range("red430").Select
Case 48
Range("red48").Select
Case 49
Range("red49").Select
Case 510
Range("red510").Select
Case 511
Range("red511").Select
Case 512
Range("red512").Select
Case 514
Range("red514").Select
Case 516
Range("red516").Select
Case 517
Range("red517").Select
Case 519
Range("red519").Select
Case 521
Range("red521").Select
Case 523
Range("red523").Select
Case 530
Range("red530").Select
Case 535
Range("red535").Select
Case 540
Range("red540").Select
Case 58
Range("red58").Select
Case 59
Range("red59").Select
Case 610
Range("red610").Select
Case 611
Range("red611").Select
Case 612
Range("red612").Select
Case 614
Range("red614").Select
Case 616
Range("red616").Select
Case 618
Range("red618").Select
Case 620
Range("red620").Select
Case 622
Range("red622").Select
Case 625
Range("red625").Select
Case 710
Range("red710").Select
Case 711
Range("red711").Select
Case 712
Range("red712").Select
Case 713
Range("red713").Select
Case 714
Range("red714").Select
Case 715
Range("red715").Select
Case 716
Range("red716").Select
Case 717
Range("red717").Select
Case 718
Range("red718").Select
Case 79
Range("red79").Select
End Select
ActiveCell.Offset(0, 1).Range("A1").Select
Selection.End(xlToRight).Select
ActiveCell.Offset(1, 1).Range("A1").Select
If ActiveCell.Offset(0, 1).Value = "" Then
ActiveCell.Offset(0, 2).Range("A1").Select
Else
ActiveCell.Offset(0, 3).Range("A1").Select
End If
Range(Selection, Selection.End(xlToRight)).Select
Range(Selection, Selection.End(xlDown)).Select
Selection.Copy
Workbooks.Add
ActiveCell.Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
:=False, Transpose:=False
Application.CutCopyMode = False
Selection.Font.ColorIndex = 3
Selection.End(xlDown).Select
Selection.End(xlToRight).Select
referprint = ActiveCell.Address
ActiveSheet.PageSetup.PrintArea = "($A$1:" & referprint & ")"
'PERSONALIZAR IMPRESIÓN
ref2 = Range("AA2001").Value
ref4 = Range("AA2000").Value
With ActiveSheet.PageSetup
.LeftHeader = ""
.CenterHeader = "ESTAS SON SUS COMBINACIONES A REDUCCIÓN AL ELEGIR " & ref2 & " BOLAS DE " & ref4 & ":"
.RightHeader = ""
.LeftFooter = ""
.CenterFooter = ""
.RightFooter = ""
.LeftMargin = Application.InchesToPoints(0.787401575)
.RightMargin = Application.InchesToPoints(0.787401575)
.TopMargin = Application.InchesToPoints(0.984251969)
.BottomMargin = Application.InchesToPoints(0.984251969)
.HeaderMargin = Application.InchesToPoints(0)
.FooterMargin = Application.InchesToPoints(0)
.PrintHeadings = False
.PrintGridlines = False
.PrintComments = xlPrintNoComments
.PrintQuality = 360
.CenterHorizontally = False
.CenterVertically = False
.Orientation = xlPortrait
.Draft = False
.PaperSize = xlPaperA4
.FirstPageNumber = xlAutomatic
.Order = xlDownThenOver
.BlackAndWhite = False
.Zoom = 100
.PrintErrors = xlPrintErrorsDisplayed
End With
ActiveWindow.SelectedSheets.PrintPreview
ActiveWindow.Close SaveChanges:=False
Windows("combobox.xls").Activate
Continuar: 'Aquí vuelve el programa si se produce el error 13
Worksheets("Sheet1").Protect Password:=5757, DrawingObjects:=True, Contents:=True, Scenarios:=True
ActiveSheet.EnableSelection = xlNoSelection
Range("C1").Select
ActiveWorkbook.Save
Exit Sub
Tratar_Errores:
Select Case Err.Number
Case 9
Resume Continuar
Case 1004
Resume Next
Case 424
Resume Next
Case Else
MsgBox ("Error # " & Err.Number & "" & Chr(13) & "" & Chr(13) & "" & Err.Description & "" & Chr(13) & "" & Chr(13) & "Contacte al programador del software para resolver el problema."), Title:="loto"
End Select
End Sub
Private Sub lista1_Change()
On Error GoTo Tratar_Errores
Dim R As String
Dim Rango As String
If lista1.ListIndex = -1 Then
MsgBox Prompt:="ASEGÚRESE DE HABER ELEGIDO UN ELEMENTO DE LAS LISTAS PREVIAS, YA QUE DE OTRA FORMA EL SOFTWARE NO FUNCIONARÁ.", Title:="loto"
Range("C1").Select
Exit Sub
End If
Range("IU2").Select
Do While ActiveCell.Value <> ""
ActiveCell.Offset(1, 0).Range("A1").Select
Loop
Continuar: 'Aquí vuelve el programa si se produce el error 13
ActiveCell.Offset(-1, 0).Range("A1").Select
R = ActiveCell.Address
Rango = ("$IU$1" & ":" & R)
lista2.ListFillRange = Rango
Range("C6").Select
Worksheets("Sheet1").Protect Password:=5757, DrawingObjects:=True, Contents:=True, Scenarios:=True
ActiveSheet.EnableSelection = xlNoSelection
Exit Sub
Tratar_Errores:
Select Case Err.Number
Case 13
Resume Continuar
Case 1004
Resume Next
Case 424
Resume Next
Case Else
MsgBox ("Error # " & Err.Number & "" & Chr(13) & "" & Chr(13) & "" & Err.Description & "" & Chr(13) & "" & Chr(13) & "Contacte al programador del software para resolver el problema."), Title:="loto"
End Select
End Sub
Private Sub lista2_Change()
On Error GoTo Tratar_Errores
Dim R As String
Dim Rango As String
If lista2.ListIndex = -1 Or lista1.ListIndex = -1 Then
MsgBox Prompt:="ASEGÚRESE DE HABER ELEGIDO UN ELEMENTO DE LAS LISTAS PREVIAS, YA QUE DE OTRA FORMA EL SOFTWARE NO FUNCIONARÁ.", Title:="loto"
Range("C1").Select
Exit Sub
End If
Range("IV2").Select
Do While ActiveCell.Value <> ""
ActiveCell.Offset(1, 0).Range("A1").Select
Loop
Continuar: 'Aquí vuelve el programa si se produce el error 13
ActiveCell.Offset(-1, 0).Range("A1").Select
R = ActiveCell.Address
Rango = ("$IV$1" & ":" & R)
lista3.ListFillRange = Rango
Call lista22
Worksheets("Sheet1").Protect Password:=5757, DrawingObjects:=True, Contents:=True, Scenarios:=True
ActiveSheet.EnableSelection = xlNoSelection
Exit Sub
Tratar_Errores:
Select Case Err.Number
Case 13
Resume Continuar
Case 1004
Resume Next
Case 424
Resume Next
Case Else
MsgBox ("Error # " & Err.Number & "" & Chr(13) & "" & Chr(13) & "" & Err.Description & "" & Chr(13) & "" & Chr(13) & "Contacte al programador del software para resolver el problema."), Title:="loto"
End Select
End Sub
Sub lista22()
On Error GoTo Tratar_Errores
Dim R, Rango As String
Range("EO2").Select
Do While ActiveCell.Value > 0
ActiveCell.Offset(1, 0).Range("A1").Select
Loop
ActiveCell.Offset(-1, 0).Range("A1").Select
R = ActiveCell.Address
Rango = ("$EO$1" & ":" & R)
Num1.ListFillRange = Rango
Num2.ListFillRange = Rango
Num3.ListFillRange = Rango
Num4.ListFillRange = Rango
Num5.ListFillRange = Rango
Num6.ListFillRange = Rango
Num7.ListFillRange = Rango
Num8.ListFillRange = Rango
Num9.ListFillRange = Rango
Num10.ListFillRange = Rango
Num11.ListFillRange = Rango
Num12.ListFillRange = Rango
Num13.ListFillRange = Rango
Num14.ListFillRange = Rango
Num15.ListFillRange = Rango
Num16.ListFillRange = Rango
Num17.ListFillRange = Rango
Num18.ListFillRange = Rango
Num19.ListFillRange = Rango
Num20.ListFillRange = Rango
Num21.ListFillRange = Rango
Num22.ListFillRange = Rango
Num23.ListFillRange = Rango
Num24.ListFillRange = Rango
Num25.ListFillRange = Rango
Num26.ListFillRange = Rango
Num27.ListFillRange = Rango
Num28.ListFillRange = Rango
Num29.ListFillRange = Rango
Num30.ListFillRange = Rango
Num31.ListFillRange = Rango
Num32.ListFillRange = Rango
Num33.ListFillRange = Rango
Num34.ListFillRange = Rango
Num35.ListFillRange = Rango
Num36.ListFillRange = Rango
Num37.ListFillRange = Rango
Num38.ListFillRange = Rango
Num39.ListFillRange = Rango
Num40.ListFillRange = Rango
Range("C6").Select
Exit Sub
Tratar_Errores:
Select Case Err.Number
Case 13
Resume Next
Case 1004
Resume Next
Case 424
Resume Next
Case Else
MsgBox ("Error # " & Err.Number & "" & Chr(13) & "" & Chr(13) & "" & Err.Description & "" & Chr(13) & "" & Chr(13) & "Contacte al programador del software para resolver el problema."), Title:="loto"
End Select
End Sub
Private Sub lista3_Change()
On Error GoTo Tratar_Errores
Dim referencia As Range
Dim referencia2 As Integer
If lista3.ListIndex = -1 Or lista2.ListIndex = -1 Or lista1.ListIndex = -1 Then
MsgBox Prompt:="ASEGÚRESE DE HABER ELEGIDO UN ELEMENTO DE LAS LISTAS PREVIAS, YA QUE DE OTRA FORMA EL SOFTWARE NO FUNCIONARÁ.", Title:="loto"
Range("C1").Select
Exit Sub
End If
Set referencia = ActiveSheet.Range("AA2001")
referencia2 = referencia.Value
Bola8.Visible = True
Num8.Visible = True
Bola9.Visible = True
Num9.Visible = True
Bola10.Visible = True
Num10.Visible = True
Bola11.Visible = True
Num11.Visible = True
Bola12.Visible = True
Num12.Visible = True
Bola13.Visible = True
Num13.Visible = True
Bola14.Visible = True
Num14.Visible = True
Bola15.Visible = True
Num15.Visible = True
Bola16.Visible = True
Num16.Visible = True
Bola17.Visible = True
Num17.Visible = True
Bola18.Visible = True
Num18.Visible = True
Bola19.Visible = True
Num19.Visible = True
Bola20.Visible = True
Num20.Visible = True
Bola21.Visible = True
Num21.Visible = True
Bola22.Visible = True
Num22.Visible = True
Bola23.Visible = True
Num23.Visible = True
Bola24.Visible = True
Num24.Visible = True
Bola25.Visible = True
Num25.Visible = True
Bola26.Visible = True
Num26.Visible = True
Bola27.Visible = True
Num27.Visible = True
Bola28.Visible = True
Num28.Visible = True
Bola29.Visible = True
Num29.Visible = True
Num30.Visible = True
Bola30.Visible = True
Bola31.Visible = True
Num31.Visible = True
Bola32.Visible = True
Num32.Visible = True
Bola33.Visible = True
Num33.Visible = True
Bola34.Visible = True
Num34.Visible = True
Bola35.Visible = True
Num35.Visible = True
Bola36.Visible = True
Num36.Visible = True
Bola37.Visible = True
Num37.Visible = True
Bola38.Visible = True
Num38.Visible = True
Bola39.Visible = True
Num39.Visible = True
Bola40.Visible = True
Num40.Visible = True
Select Case referencia2
Case 39
Bola40.Visible = False
Num40.Visible = False
Case 38
Bola39.Visible = False
Num39.Visible = False
Bola40.Visible = False
Num40.Visible = False
Case 37
Bola38.Visible = False
Num38.Visible = False
Bola39.Visible = False
Num39.Visible = False
Bola40.Visible = False
Num40.Visible = False
Case 36
Bola37.Visible = False
Num37.Visible = False
Bola38.Visible = False
Num38.Visible = False
Bola39.Visible = False
Num39.Visible = False
Bola40.Visible = False
Num40.Visible = False
Case 35
Bola36.Visible = False
Num36.Visible = False
Bola37.Visible = False
Num37.Visible = False
Bola38.Visible = False
Num38.Visible = False
Bola39.Visible = False
Num39.Visible = False
Bola40.Visible = False
Num40.Visible = False
Case 34
Bola35.Visible = False
Num35.Visible = False
Bola36.Visible = False
Num36.Visible = False
Bola37.Visible = False
Num37.Visible = False
Bola38.Visible = False
Num38.Visible = False
Bola39.Visible = False
Num39.Visible = False
Bola40.Visible = False
Num40.Visible = False
Case 33
Bola34.Visible = False
Num34.Visible = False
Bola35.Visible = False
Num35.Visible = False
Bola36.Visible = False
Num36.Visible = False
Bola37.Visible = False
Num37.Visible = False
Bola38.Visible = False
Num38.Visible = False
Bola39.Visible = False
Num39.Visible = False
Bola40.Visible = False
Num40.Visible = False
Case 32
Bola33.Visible = False
Num33.Visible = False
Bola34.Visible = False
Num34.Visible = False
Bola35.Visible = False
Num35.Visible = False
Bola36.Visible = False
Num36.Visible = False
Bola37.Visible = False
Num37.Visible = False
Bola38.Visible = False
Num38.Visible = False
Bola39.Visible = False
Num39.Visible = False
Bola40.Visible = False
Num40.Visible = False
Case 31
Bola32.Visible = False
Num32.Visible = False
Bola33.Visible = False
Num33.Visible = False
Bola34.Visible = False
Num34.Visible = False
Bola35.Visible = False
Num35.Visible = False
Bola36.Visible = False
Num36.Visible = False
Bola37.Visible = False
Num37.Visible = False
Bola38.Visible = False
Num38.Visible = False
Bola39.Visible = False
Num39.Visible = False
Bola40.Visible = False
Num40.Visible = False
Case 30
Bola31.Visible = False
Num31.Visible = False
Bola32.Visible = False
Num32.Visible = False
Bola33.Visible = False
Num33.Visible = False
Bola34.Visible = False
Num34.Visible = False
Bola35.Visible = False
Num35.Visible = False
Bola36.Visible = False
Num36.Visible = False
Bola37.Visible = False
Num37.Visible = False
Bola38.Visible = False
Num38.Visible = False
Bola39.Visible = False
Num39.Visible = False
Bola40.Visible = False
Num40.Visible = False
Case 29
Bola30.Visible = False
Num30.Visible = False
Bola31.Visible = False
Num31.Visible = False
Bola32.Visible = False
Num32.Visible = False
Bola33.Visible = False
Num33.Visible = False
Bola34.Visible = False
Num34.Visible = False
Bola35.Visible = False
Num35.Visible = False
Bola36.Visible = False
Num36.Visible = False
Bola37.Visible = False
Num37.Visible = False
Bola38.Visible = False
Num38.Visible = False
Bola39.Visible = False
Num39.Visible = False
Bola40.Visible = False
Num40.Visible = False
Case 28
Bola29.Visible = False
Num29.Visible = False
Bola30.Visible = False
Num30.Visible = False
Bola31.Visible = False
Num31.Visible = False
Bola32.Visible = False
Num32.Visible = False
Bola33.Visible = False
Num33.Visible = False
Bola34.Visible = False
Num34.Visible = False
Bola35.Visible = False
Num35.Visible = False
Bola36.Visible = False
Num36.Visible = False
Bola37.Visible = False
Num37.Visible = False
Bola38.Visible = False
Num38.Visible = False
Bola39.Visible = False
Num39.Visible = False
Bola40.Visible = False
Num40.Visible = False
Case 27
Bola28.Visible = False
Num28.Visible = False
Bola29.Visible = False
Num29.Visible = False
Bola30.Visible = False
Num30.Visible = False
Bola31.Visible = False
Num31.Visible = False
Bola32.Visible = False
Num32.Visible = False
Bola33.Visible = False
Num33.Visible = False
Bola34.Visible = False
Num34.Visible = False
Bola35.Visible = False
Num35.Visible = False
Bola36.Visible = False
Num36.Visible = False
Bola37.Visible = False
Num37.Visible = False
Bola38.Visible = False
Num38.Visible = False
Bola39.Visible = False
Num39.Visible = False
Bola40.Visible = False
Num40.Visible = False
Case 26
Bola27.Visible = False
Num27.Visible = False
Bola28.Visible = False
Num28.Visible = False
Bola29.Visible = False
Num29.Visible = False
Bola30.Visible = False
Num30.Visible = False
Bola31.Visible = False
Num31.Visible = False
Bola32.Visible = False
Num32.Visible = False
Bola33.Visible = False
Num33.Visible = False
Bola34.Visible = False
Num34.Visible = False
Bola35.Visible = False
Num35.Visible = False
Bola36.Visible = False
Num36.Visible = False
Bola37.Visible = False
Num37.Visible = False
Bola38.Visible = False
Num38.Visible = False
Bola39.Visible = False
Num39.Visible = False
Bola40.Visible = False
Num40.Visible = False
Case 25
Bola26.Visible = False
Num26.Visible = False
Bola27.Visible = False
Num27.Visible = False
Bola28.Visible = False
Num28.Visible = False
Bola29.Visible = False
Num29.Visible = False
Bola30.Visible = False
Num30.Visible = False
Bola31.Visible = False
Num31.Visible = False
Bola32.Visible = False
Num32.Visible = False
Bola33.Visible = False
Num33.Visible = False
Bola34.Visible = False
Num34.Visible = False
Bola35.Visible = False
Num35.Visible = False
Bola36.Visible = False
Num36.Visible = False
Bola37.Visible = False
Num37.Visible = False
Bola38.Visible = False
Num38.Visible = False
Bola39.Visible = False
Num39.Visible = False
Bola40.Visible = False
Num40.Visible = False
Case 24
Bola25.Visible = False
Num25.Visible = False
Bola26.Visible = False
Num26.Visible = False
Bola27.Visible = False
Num27.Visible = False
Bola28.Visible = False
Num28.Visible = False
Bola29.Visible = False
Num29.Visible = False
Num30.Visible = False
Bola30.Visible = False
Bola31.Visible = False
Num31.Visible = False
Bola32.Visible = False
Num32.Visible = False
Bola33.Visible = False
Num33.Visible = False
Bola34.Visible = False
Num34.Visible = False
Bola35.Visible = False
Num35.Visible = False
Bola36.Visible = False
Num36.Visible = False
Bola37.Visible = False
Num37.Visible = False
Bola38.Visible = False
Num38.Visible = False
Bola39.Visible = False
Num39.Visible = False
Bola40.Visible = False
Num40.Visible = False
Case 23
Bola24.Visible = False
Num24.Visible = False
Bola25.Visible = False
Num25.Visible = False
Bola26.Visible = False
Num26.Visible = False
Bola27.Visible = False
Num27.Visible = False
Bola28.Visible = False
Num28.Visible = False
Bola29.Visible = False
Num29.Visible = False
Num30.Visible = False
Bola30.Visible = False
Bola31.Visible = False
Num31.Visible = False
Bola32.Visible = False
Num32.Visible = False
Bola33.Visible = False
Num33.Visible = False
Bola34.Visible = False
Num34.Visible = False
Bola35.Visible = False
Num35.Visible = False
Bola36.Visible = False
Num36.Visible = False
Bola37.Visible = False
Num37.Visible = False
Bola38.Visible = False
Num38.Visible = False
Bola39.Visible = False
Num39.Visible = False
Bola40.Visible = False
Num40.Visible = False
Case 22
Bola23.Visible = False
Num23.Visible = False
Bola24.Visible = False
Num24.Visible = False
Bola25.Visible = False
Num25.Visible = False
Bola26.Visible = False
Num26.Visible = False
Bola27.Visible = False
Num27.Visible = False
Bola28.Visible = False
Num28.Visible = False
Bola29.Visible = False
Num29.Visible = False
Num30.Visible = False
Bola30.Visible = False
Bola31.Visible = False
Num31.Visible = False
Bola32.Visible = False
Num32.Visible = False
Bola33.Visible = False
Num33.Visible = False
Bola34.Visible = False
Num34.Visible = False
Bola35.Visible = False
Num35.Visible = False
Bola36.Visible = False
Num36.Visible = False
Bola37.Visible = False
Num37.Visible = False
Bola38.Visible = False
Num38.Visible = False
Bola39.Visible = False
Num39.Visible = False
Bola40.Visible = False
Num40.Visible = False
Case 21
Bola22.Visible = False
Num22.Visible = False
Bola23.Visible = False
Num23.Visible = False
Bola24.Visible = False
Num24.Visible = False
Bola25.Visible = False
Num25.Visible = False
Bola26.Visible = False
Num26.Visible = False
Bola27.Visible = False
Num27.Visible = False
Bola28.Visible = False
Num28.Visible = False
Bola29.Visible = False
Num29.Visible = False
Num30.Visible = False
Bola30.Visible = False
Bola31.Visible = False
Num31.Visible = False
Bola32.Visible = False
Num32.Visible = False
Bola33.Visible = False
Num33.Visible = False
Bola34.Visible = False
Num34.Visible = False
Bola35.Visible = False
Num35.Visible = False
Bola36.Visible = False
Num36.Visible = False
Bola37.Visible = False
Num37.Visible = False
Bola38.Visible = False
Num38.Visible = False
Bola39.Visible = False
Num39.Visible = False
Bola40.Visible = False
Num40.Visible = False
Case 20
Bola21.Visible = False
Num21.Visible = False
Bola22.Visible = False
Num22.Visible = False
Bola23.Visible = False
Num23.Visible = False
Bola24.Visible = False
Num24.Visible = False
Bola25.Visible = False
Num25.Visible = False
Bola26.Visible = False
Num26.Visible = False
Bola27.Visible = False
Num27.Visible = False
Bola28.Visible = False
Num28.Visible = False
Bola29.Visible = False
Num29.Visible = False
Num30.Visible = False
Bola30.Visible = False
Bola31.Visible = False
Num31.Visible = False
Bola32.Visible = False
Num32.Visible = False
Bola33.Visible = False
Num33.Visible = False
Bola34.Visible = False
Num34.Visible = False
Bola35.Visible = False
Num35.Visible = False
Bola36.Visible = False
Num36.Visible = False
Bola37.Visible = False
Num37.Visible = False
Bola38.Visible = False
Num38.Visible = False
Bola39.Visible = False
Num39.Visible = False
Bola40.Visible = False
Num40.Visible = False
Case 19
Bola20.Visible = False
Num20.Visible = False
Bola21.Visible = False
Num21.Visible = False
Bola22.Visible = False
Num22.Visible = False
Bola23.Visible = False
Num23.Visible = False
Bola24.Visible = False
Num24.Visible = False
Bola25.Visible = False
Num25.Visible = False
Bola26.Visible = False
Num26.Visible = False
Bola27.Visible = False
Num27.Visible = False
Bola28.Visible = False
Num28.Visible = False
Bola29.Visible = False
Num29.Visible = False
Num30.Visible = False
Bola30.Visible = False
Bola31.Visible = False
Num31.Visible = False
Bola32.Visible = False
Num32.Visible = False
Bola33.Visible = False
Num33.Visible = False
Bola34.Visible = False
Num34.Visible = False
Bola35.Visible = False
Num35.Visible = False
Bola36.Visible = False
Num36.Visible = False
Bola37.Visible = False
Num37.Visible = False
Bola38.Visible = False
Num38.Visible = False
Bola39.Visible = False
Num39.Visible = False
Bola40.Visible = False
Num40.Visible = False
Case 18
Bola19.Visible = False
Num19.Visible = False
Bola20.Visible = False
Num20.Visible = False
Bola21.Visible = False
Num21.Visible = False
Bola22.Visible = False
Num22.Visible = False
Bola23.Visible = False
Num23.Visible = False
Bola24.Visible = False
Num24.Visible = False
Bola25.Visible = False
Num25.Visible = False
Bola26.Visible = False
Num26.Visible = False
Bola27.Visible = False
Num27.Visible = False
Bola28.Visible = False
Num28.Visible = False
Bola29.Visible = False
Num29.Visible = False
Num30.Visible = False
Bola30.Visible = False
Bola31.Visible = False
Num31.Visible = False
Bola32.Visible = False
Num32.Visible = False
Bola33.Visible = False
Num33.Visible = False
Bola34.Visible = False
Num34.Visible = False
Bola35.Visible = False
Num35.Visible = False
Bola36.Visible = False
Num36.Visible = False
Bola37.Visible = False
Num37.Visible = False
Bola38.Visible = False
Num38.Visible = False
Bola39.Visible = False
Num39.Visible = False
Bola40.Visible = False
Num40.Visible = False
Case 17
Bola18.Visible = False
Num18.Visible = False
Bola19.Visible = False
Num19.Visible = False
Bola20.Visible = False
Num20.Visible = False
Bola21.Visible = False
Num21.Visible = False
Bola22.Visible = False
Num22.Visible = False
Bola23.Visible = False
Num23.Visible = False
Bola24.Visible = False
Num24.Visible = False
Bola25.Visible = False
Num25.Visible = False
Bola26.Visible = False
Num26.Visible = False
Bola27.Visible = False
Num27.Visible = False
Bola28.Visible = False
Num28.Visible = False
Bola29.Visible = False
Num29.Visible = False
Num30.Visible = False
Bola30.Visible = False
Bola31.Visible = False
Num31.Visible = False
Bola32.Visible = False
Num32.Visible = False
Bola33.Visible = False
Num33.Visible = False
Bola34.Visible = False
Num34.Visible = False
Bola35.Visible = False
Num35.Visible = False
Bola36.Visible = False
Num36.Visible = False
Bola37.Visible = False
Num37.Visible = False
Bola38.Visible = False
Num38.Visible = False
Bola39.Visible = False
Num39.Visible = False
Bola40.Visible = False
Num40.Visible = False
Case 16
Bola17.Visible = False
Num17.Visible = False
Bola18.Visible = False
Num18.Visible = False
Bola19.Visible = False
Num19.Visible = False
Bola20.Visible = False
Num20.Visible = False
Bola21.Visible = False
Num21.Visible = False
Bola22.Visible = False
Num22.Visible = False
Bola23.Visible = False
Num23.Visible = False
Bola24.Visible = False
Num24.Visible = False
Bola25.Visible = False
Num25.Visible = False
Bola26.Visible = False
Num26.Visible = False
Bola27.Visible = False
Num27.Visible = False
Bola28.Visible = False
Num28.Visible = False
Bola29.Visible = False
Num29.Visible = False
Num30.Visible = False
Bola30.Visible = False
Bola31.Visible = False
Num31.Visible = False
Bola32.Visible = False
Num32.Visible = False
Bola33.Visible = False
Num33.Visible = False
Bola34.Visible = False
Num34.Visible = False
Bola35.Visible = False
Num35.Visible = False
Bola36.Visible = False
Num36.Visible = False
Bola37.Visible = False
Num37.Visible = False
Bola38.Visible = False
Num38.Visible = False
Bola39.Visible = False
Num39.Visible = False
Bola40.Visible = False
Num40.Visible = False
Case 15
Bola16.Visible = False
Num16.Visible = False
Bola17.Visible = False
Num17.Visible = False
Bola18.Visible = False
Num18.Visible = False
Bola19.Visible = False
Num19.Visible = False
Bola20.Visible = False
Num20.Visible = False
Bola21.Visible = False
Num21.Visible = False
Bola22.Visible = False
Num22.Visible = False
Bola23.Visible = False
Num23.Visible = False
Bola24.Visible = False
Num24.Visible = False
Bola25.Visible = False
Num25.Visible = False
Bola26.Visible = False
Num26.Visible = False
Bola27.Visible = False
Num27.Visible = False
Bola28.Visible = False
Num28.Visible = False
Bola29.Visible = False
Num29.Visible = False
Num30.Visible = False
Bola30.Visible = False
Bola31.Visible = False
Num31.Visible = False
Bola32.Visible = False
Num32.Visible = False
Bola33.Visible = False
Num33.Visible = False
Bola34.Visible = False
Num34.Visible = False
Bola35.Visible = False
Num35.Visible = False
Bola36.Visible = False
Num36.Visible = False
Bola37.Visible = False
Num37.Visible = False
Bola38.Visible = False
Num38.Visible = False
Bola39.Visible = False
Num39.Visible = False
Bola40.Visible = False
Num40.Visible = False
Case 14
Bola15.Visible = False
Num15.Visible = False
Bola16.Visible = False
Num16.Visible = False
Bola17.Visible = False
Num17.Visible = False
Bola18.Visible = False
Num18.Visible = False
Bola19.Visible = False
Num19.Visible = False
Bola20.Visible = False
Num20.Visible = False
Bola21.Visible = False
Num21.Visible = False
Bola22.Visible = False
Num22.Visible = False
Bola23.Visible = False
Num23.Visible = False
Bola24.Visible = False
Num24.Visible = False
Bola25.Visible = False
Num25.Visible = False
Bola26.Visible = False
Num26.Visible = False
Bola27.Visible = False
Num27.Visible = False
Bola28.Visible = False
Num28.Visible = False
Bola29.Visible = False
Num29.Visible = False
Num30.Visible = False
Bola30.Visible = False
Bola31.Visible = False
Num31.Visible = False
Bola32.Visible = False
Num32.Visible = False
Bola33.Visible = False
Num33.Visible = False
Bola34.Visible = False
Num34.Visible = False
Bola35.Visible = False
Num35.Visible = False
Bola36.Visible = False
Num36.Visible = False
Bola37.Visible = False
Num37.Visible = False
Bola38.Visible = False
Num38.Visible = False
Bola39.Visible = False
Num39.Visible = False
Bola40.Visible = False
Num40.Visible = False
Case 13
Bola14.Visible = False
Num14.Visible = False
Bola15.Visible = False
Num15.Visible = False
Bola16.Visible = False
Num16.Visible = False
Bola17.Visible = False
Num17.Visible = False
Bola18.Visible = False
Num18.Visible = False
Bola19.Visible = False
Num19.Visible = False
Bola20.Visible = False
Num20.Visible = False
Bola21.Visible = False
Num21.Visible = False
Bola22.Visible = False
Num22.Visible = False
Bola23.Visible = False
Num23.Visible = False
Bola24.Visible = False
Num24.Visible = False
Bola25.Visible = False
Num25.Visible = False
Bola26.Visible = False
Num26.Visible = False
Bola27.Visible = False
Num27.Visible = False
Bola28.Visible = False
Num28.Visible = False
Bola29.Visible = False
Num29.Visible = False
Num30.Visible = False
Bola30.Visible = False
Bola31.Visible = False
Num31.Visible = False
Bola32.Visible = False
Num32.Visible = False
Bola33.Visible = False
Num33.Visible = False
Bola34.Visible = False
Num34.Visible = False
Bola35.Visible = False
Num35.Visible = False
Bola36.Visible = False
Num36.Visible = False
Bola37.Visible = False
Num37.Visible = False
Bola38.Visible = False
Num38.Visible = False
Bola39.Visible = False
Num39.Visible = False
Bola40.Visible = False
Num40.Visible = False
Case 12
Bola13.Visible = False
Num13.Visible = False
Bola14.Visible = False
Num14.Visible = False
Bola15.Visible = False
Num15.Visible = False
Bola16.Visible = False
Num16.Visible = False
Bola17.Visible = False
Num17.Visible = False
Bola18.Visible = False
Num18.Visible = False
Bola19.Visible = False
Num19.Visible = False
Bola20.Visible = False
Num20.Visible = False
Bola21.Visible = False
Num21.Visible = False
Bola22.Visible = False
Num22.Visible = False
Bola23.Visible = False
Num23.Visible = False
Bola24.Visible = False
Num24.Visible = False
Bola25.Visible = False
Num25.Visible = False
Bola26.Visible = False
Num26.Visible = False
Bola27.Visible = False
Num27.Visible = False
Bola28.Visible = False
Num28.Visible = False
Bola29.Visible = False
Num29.Visible = False
Num30.Visible = False
Bola30.Visible = False
Bola31.Visible = False
Num31.Visible = False
Bola32.Visible = False
Num32.Visible = False
Bola33.Visible = False
Num33.Visible = False
Bola34.Visible = False
Num34.Visible = False
Bola35.Visible = False
Num35.Visible = False
Bola36.Visible = False
Num36.Visible = False
Bola37.Visible = False
Num37.Visible = False
Bola38.Visible = False
Num38.Visible = False
Bola39.Visible = False
Num39.Visible = False
Bola40.Visible = False
Num40.Visible = False
Case 11
Bola12.Visible = False
Num12.Visible = False
Bola13.Visible = False
Num13.Visible = False
Bola14.Visible = False
Num14.Visible = False
Bola15.Visible = False
Num15.Visible = False
Bola16.Visible = False
Num16.Visible = False
Bola17.Visible = False
Num17.Visible = False
Bola18.Visible = False
Num18.Visible = False
Bola19.Visible = False
Num19.Visible = False
Bola20.Visible = False
Num20.Visible = False
Bola21.Visible = False
Num21.Visible = False
Bola22.Visible = False
Num22.Visible = False
Bola23.Visible = False
Num23.Visible = False
Bola24.Visible = False
Num24.Visible = False
Bola25.Visible = False
Num25.Visible = False
Bola26.Visible = False
Num26.Visible = False
Bola27.Visible = False
Num27.Visible = False
Bola28.Visible = False
Num28.Visible = False
Bola29.Visible = False
Num29.Visible = False
Num30.Visible = False
Bola30.Visible = False
Bola31.Visible = False
Num31.Visible = False
Bola32.Visible = False
Num32.Visible = False
Bola33.Visible = False
Num33.Visible = False
Bola34.Visible = False
Num34.Visible = False
Bola35.Visible = False
Num35.Visible = False
Bola36.Visible = False
Num36.Visible = False
Bola37.Visible = False
Num37.Visible = False
Bola38.Visible = False
Num38.Visible = False
Bola39.Visible = False
Num39.Visible = False
Bola40.Visible = False
Num40.Visible = False
Case 10
Bola11.Visible = False
Num11.Visible = False
Bola12.Visible = False
Num12.Visible = False
Bola13.Visible = False
Num13.Visible = False
Bola14.Visible = False
Num14.Visible = False
Bola15.Visible = False
Num15.Visible = False
Bola16.Visible = False
Num16.Visible = False
Bola17.Visible = False
Num17.Visible = False
Bola18.Visible = False
Num18.Visible = False
Bola19.Visible = False
Num19.Visible = False
Bola20.Visible = False
Num20.Visible = False
Bola21.Visible = False
Num21.Visible = False
Bola22.Visible = False
Num22.Visible = False
Bola23.Visible = False
Num23.Visible = False
Bola24.Visible = False
Num24.Visible = False
Bola25.Visible = False
Num25.Visible = False
Bola26.Visible = False
Num26.Visible = False
Bola27.Visible = False
Num27.Visible = False
Bola28.Visible = False
Num28.Visible = False
Bola29.Visible = False
Num29.Visible = False
Num30.Visible = False
Bola30.Visible = False
Bola31.Visible = False
Num31.Visible = False
Bola32.Visible = False
Num32.Visible = False
Bola33.Visible = False
Num33.Visible = False
Bola34.Visible = False
Num34.Visible = False
Bola35.Visible = False
Num35.Visible = False
Bola36.Visible = False
Num36.Visible = False
Bola37.Visible = False
Num37.Visible = False
Bola38.Visible = False
Num38.Visible = False
Bola39.Visible = False
Num39.Visible = False
Bola40.Visible = False
Num40.Visible = False
Case 9
Bola10.Visible = False
Num10.Visible = False
Bola11.Visible = False
Num11.Visible = False
Bola12.Visible = False
Num12.Visible = False
Bola13.Visible = False
Num13.Visible = False
Bola14.Visible = False
Num14.Visible = False
Bola15.Visible = False
Num15.Visible = False
Bola16.Visible = False
Num16.Visible = False
Bola17.Visible = False
Num17.Visible = False
Bola18.Visible = False
Num18.Visible = False
Bola19.Visible = False
Num19.Visible = False
Bola20.Visible = False
Num20.Visible = False
Bola21.Visible = False
Num21.Visible = False
Bola22.Visible = False
Num22.Visible = False
Bola23.Visible = False
Num23.Visible = False
Bola24.Visible = False
Num24.Visible = False
Bola25.Visible = False
Num25.Visible = False
Bola26.Visible = False
Num26.Visible = False
Bola27.Visible = False
Num27.Visible = False
Bola28.Visible = False
Num28.Visible = False
Bola29.Visible = False
Num29.Visible = False
Num30.Visible = False
Bola30.Visible = False
Bola31.Visible = False
Num31.Visible = False
Bola32.Visible = False
Num32.Visible = False
Bola33.Visible = False
Num33.Visible = False
Bola34.Visible = False
Num34.Visible = False
Bola35.Visible = False
Num35.Visible = False
Bola36.Visible = False
Num36.Visible = False
Bola37.Visible = False
Num37.Visible = False
Bola38.Visible = False
Num38.Visible = False
Bola39.Visible = False
Num39.Visible = False
Bola40.Visible = False
Num40.Visible = False
Case 8
Bola9.Visible = False
Num9.Visible = False
Bola10.Visible = False
Num10.Visible = False
Bola11.Visible = False
Num11.Visible = False
Bola12.Visible = False
Num12.Visible = False
Bola13.Visible = False
Num13.Visible = False
Bola14.Visible = False
Num14.Visible = False
Bola15.Visible = False
Num15.Visible = False
Bola16.Visible = False
Num16.Visible = False
Bola17.Visible = False
Num17.Visible = False
Bola18.Visible = False
Num18.Visible = False
Bola19.Visible = False
Num19.Visible = False
Bola20.Visible = False
Num20.Visible = False
Bola21.Visible = False
Num21.Visible = False
Bola22.Visible = False
Num22.Visible = False
Bola23.Visible = False
Num23.Visible = False
Bola24.Visible = False
Num24.Visible = False
Bola25.Visible = False
Num25.Visible = False
Bola26.Visible = False
Num26.Visible = False
Bola27.Visible = False
Num27.Visible = False
Bola28.Visible = False
Num28.Visible = False
Bola29.Visible = False
Num29.Visible = False
Num30.Visible = False
Bola30.Visible = False
Bola31.Visible = False
Num31.Visible = False
Bola32.Visible = False
Num32.Visible = False
Bola33.Visible = False
Num33.Visible = False
Bola34.Visible = False
Num34.Visible = False
Bola35.Visible = False
Num35.Visible = False
Bola36.Visible = False
Num36.Visible = False
Bola37.Visible = False
Num37.Visible = False
Bola38.Visible = False
Num38.Visible = False
Bola39.Visible = False
Num39.Visible = False
Bola40.Visible = False
Num40.Visible = False
Case 7
Bola8.Visible = False
Num8.Visible = False
Bola9.Visible = False
Num9.Visible = False
Bola10.Visible = False
Num10.Visible = False
Bola11.Visible = False
Num11.Visible = False
Bola12.Visible = False
Num12.Visible = False
Bola13.Visible = False
Num13.Visible = False
Bola14.Visible = False
Num14.Visible = False
Bola15.Visible = False
Num15.Visible = False
Bola16.Visible = False
Num16.Visible = False
Bola17.Visible = False
Num17.Visible = False
Bola18.Visible = False
Num18.Visible = False
Bola19.Visible = False
Num19.Visible = False
Bola20.Visible = False
Num20.Visible = False
Bola21.Visible = False
Num21.Visible = False
Bola22.Visible = False
Num22.Visible = False
Bola23.Visible = False
Num23.Visible = False
Bola24.Visible = False
Num24.Visible = False
Bola25.Visible = False
Num25.Visible = False
Bola26.Visible = False
Num26.Visible = False
Bola27.Visible = False
Num27.Visible = False
Bola28.Visible = False
Num28.Visible = False
Bola29.Visible = False
Num29.Visible = False
Num30.Visible = False
Bola30.Visible = False
Bola31.Visible = False
Num31.Visible = False
Bola32.Visible = False
Num32.Visible = False
Bola33.Visible = False
Num33.Visible = False
Bola34.Visible = False
Num34.Visible = False
Bola35.Visible = False
Num35.Visible = False
Bola36.Visible = False
Num36.Visible = False
Bola37.Visible = False
Num37.Visible = False
Bola38.Visible = False
Num38.Visible = False
Bola39.Visible = False
Num39.Visible = False
Bola40.Visible = False
Num40.Visible = False
End Select
Range("C10").Select
Worksheets("Sheet1").Protect Password:=5757, DrawingObjects:=True, Contents:=True, Scenarios:=True
ActiveSheet.EnableSelection = xlNoSelection
Exit Sub
Tratar_Errores:
Select Case Err.Number
Case 13
MsgBox Prompt:="ASEGÚRESE DE HABER ELEGIDO UN ELEMENTO DE LAS LISTAS PREVIAS, YA QUE DE OTRA FORMA EL SOFTWARE NO FUNCIONARÁ.", Title:="loto"
Range("C1").Select
Exit Sub
Case 1004
Resume Next
Case 424
Resume Next
Case Else
MsgBox ("Error # " & Err.Number & "" & Chr(13) & "" & Chr(13) & "" & Err.Description & "" & Chr(13) & "" & Chr(13) & "Contacte al programador del software para resolver el problema."), Title:="loto"
End Select
End Sub