Option Explicit
'richiesta scrip già esistente di armando59
'http://forum.lottoced.com/forum/lottoced/area-download/2037921-richiesta-scrip-gi%C3%A0-esistente
Sub Main()
Dim T
T = "********* CADENZE , FIGURE , DECINE , SOMME E DISTANZE TRA GLI ESTRATTI BY BLACKMORE ********"
Call Scrivi(T,True,,vbBlue,05,05)
Call Scrivi()
Call Scrivi("Questo Script mostra le Cadenze , Figure , Decine , Somme e Distanze ",01,,,,03)
Call Scrivi("tra gli estratti , evidenziando quelle uguali ",01,,,,03)
Call Scrivi()
Call Scrivi(" Cadenze , Figure , Decine ",01,,,,04)
ReDim T01(17)
T01(01) = " Ruota "
T01(02) = " Estratti Ruota "
T01(03) = " Cad 1° "
T01(04) = " Cad 2° "
T01(05) = " Cad 3° "
T01(06) = " Cad 4° "
T01(07) = " Cad 5° "
T01(08) = " Fig 1° "
T01(09) = " Fig 2° "
T01(10) = " Fig 3° "
T01(11) = " Fig 4° "
T01(12) = " Fig 5° "
T01(13) = " Dec 1° "
T01(14) = " Dec 2° "
T01(15) = " Dec 3° "
T01(16) = " Dec 4° "
T01(17) = " Dec 5° "
Call InitTabella(T01,RGB(251,125,000),,02)
Dim es
es = EstrazioneFin
Dim r
For r = 01 To 11
If r = 11 Then r = 12
Call Messaggio(r)
Call AvanzamentoElab(01,12,r)
Dim Cad01,Cad02,Cad03,Cad04,Cad05
Cad01 = Cadenza(Estratto(es,r,01))
Cad02 = Cadenza(Estratto(es,r,02))
Cad03 = Cadenza(Estratto(es,r,03))
Cad04 = Cadenza(Estratto(es,r,04))
Cad05 = Cadenza(Estratto(es,r,05))
Dim Fig01,Fig02,Fig03,Fig04,Fig05
Fig01 = Figura(Estratto(es,r,01))
Fig02 = Figura(Estratto(es,r,02))
Fig03 = Figura(Estratto(es,r,03))
Fig04 = Figura(Estratto(es,r,04))
Fig05 = Figura(Estratto(es,r,05))
Dim Dec01,Dec02,Dec03,Dec04,Dec05
Dec01 = Decina(Estratto(es,r,01))
Dec02 = Decina(Estratto(es,r,02))
Dec03 = Decina(Estratto(es,r,03))
Dec04 = Decina(Estratto(es,r,04))
Dec05 = Decina(Estratto(es,r,05))
ReDim V01(17)
V01(01) = NomeRuota(r)
V01(02) = StringaEstratti(es,r)
V01(03) = Cad01
V01(04) = Cad02
V01(05) = Cad03
V01(06) = Cad04
V01(07) = Cad05
V01(08) = Fig01
V01(09) = Fig02
V01(10) = Fig03
V01(11) = Fig04
V01(12) = Fig05
V01(13) = Dec01
V01(14) = Dec02
V01(15) = Dec03
V01(16) = Dec04
V01(17) = Dec05
Call AddRigaTabella(V01,,,04,,01)
Call SetColoreCella(01,RGB(207,207,207))
Call SetColoreCella(02,RGB(239,239,239))
Call SetColoreCella(03,vbYellow)
Call SetColoreCella(04,vbYellow)
Call SetColoreCella(05,vbYellow)
Call SetColoreCella(06,vbYellow)
Call SetColoreCella(07,vbYellow)
Call SetColoreCella(08,vbCyan)
Call SetColoreCella(09,vbCyan)
Call SetColoreCella(10,vbCyan)
Call SetColoreCella(11,vbCyan)
Call SetColoreCella(12,vbCyan)
Call SetColoreCella(13,vbYellow)
Call SetColoreCella(14,vbYellow)
Call SetColoreCella(15,vbYellow)
Call SetColoreCella(16,vbYellow)
Call SetColoreCella(17,vbYellow)
Dim x01,x02
For x01 = 03 To 06
For x02 = x01 + 01 To 07
If V01(x01) = V01(x02) Then Call SetColoreCella((x01),RGB(223,000,223),05)
If V01(x02) = V01(x01) Then Call SetColoreCella((x02),RGB(223,000,223),05)
Next
Next
Dim x03,x04
For x03 = 08 To 11
For x04 = x03 + 01 To 12
If V01(x03) = V01(x04) Then Call SetColoreCella((x03),RGB(150,075,075),05)
If V01(x04) = V01(x03) Then Call SetColoreCella((x04),RGB(150,075,075),05)
Next
Next
Dim x05,x06
For x05 = 13 To 16
For x06 = x05 + 01 To 17
If V01(x05) = V01(x06) Then Call SetColoreCella((x05),RGB(223,000,223),05)
If V01(x06) = V01(x05) Then Call SetColoreCella((x06),RGB(223,000,223),05)
Next
Next
Next
Call CreaTabella()
'--------------------------------------------------------------------------------------------------
Call Scrivi(" Somme tra gli estratti e Somma totale ",01,,,,04)
ReDim T02(13)
T02(01) = " Ruota "
T02(02) = " Estratti Ruota "
T02(03) = " 1° - 2° "
T02(04) = " 1° - 3° "
T02(05) = " 1° - 4° "
T02(06) = " 1° - 5° "
T02(07) = " 2° - 3° "
T02(08) = " 2° - 4° "
T02(09) = " 2° - 5° "
T02(10) = " 3° - 4° "
T02(11) = " 3° - 5° "
T02(12) = " 4° - 5° "
T02(13) = " Somma Estratti "
Call InitTabella(T02,RGB(251,125,000),,02)
For r = 01 To 11
If r = 11 Then r = 12
Dim Som01,Som02,Som03,Som04,Som05,Som06,Som07,Som08,Som09,Som10,SomTot
Som01 = Fuori90(Estratto(es,r,01) + Estratto(es,r,02))
Som02 = Fuori90(Estratto(es,r,01) + Estratto(es,r,03))
Som03 = Fuori90(Estratto(es,r,01) + Estratto(es,r,04))
Som04 = Fuori90(Estratto(es,r,01) + Estratto(es,r,05))
Som05 = Fuori90(Estratto(es,r,02) + Estratto(es,r,03))
Som06 = Fuori90(Estratto(es,r,02) + Estratto(es,r,04))
Som07 = Fuori90(Estratto(es,r,02) + Estratto(es,r,05))
Som08 = Fuori90(Estratto(es,r,03) + Estratto(es,r,04))
Som09 = Fuori90(Estratto(es,r,03) + Estratto(es,r,05))
Som10 = Fuori90(Estratto(es,r,04) + Estratto(es,r,05))
SomTot = SommaEstratti(es,r)
ReDim V02(13)
V02(01) = NomeRuota(r)
V02(02) = StringaEstratti(es,r)
V02(03) = Som01
V02(04) = Som02
V02(05) = Som03
V02(06) = Som04
V02(07) = Som05
V02(08) = Som06
V02(09) = Som07
V02(10) = Som08
V02(11) = Som09
V02(12) = Som10
V02(13) = SomTot
Call AddRigaTabella(V02,,,04,,01)
Call SetColoreCella(01,RGB(207,207,207))
Call SetColoreCella(02,RGB(239,239,239))
Call SetColoreCella(03,vbCyan)
Call SetColoreCella(04,vbCyan)
Call SetColoreCella(05,vbCyan)
Call SetColoreCella(06,vbCyan)
Call SetColoreCella(07,vbCyan)
Call SetColoreCella(08,vbCyan)
Call SetColoreCella(09,vbCyan)
Call SetColoreCella(10,vbCyan)
Call SetColoreCella(11,vbCyan)
Call SetColoreCella(12,vbCyan)
Call SetColoreCella(13,vbYellow)
Dim x07,x08
For x07 = 03 To 11
For x08 = x07 + 01 To 12
If V02(x07) = V02(x08) Then Call SetColoreCella((x07),RGB(150,075,075),05)
If V02(x08) = V02(x07) Then Call SetColoreCella((x08),RGB(150,075,075),05)
Next
Next
Next
Call CreaTabella()
'--------------------------------------------------------------------------------------------------
Call Scrivi(" Differenze Ciclometriche tra gli estratti ",01,,,,04)
ReDim T03(12)
T03(01) = " Ruota "
T03(02) = " Estratti Ruota "
T03(03) = " 1° - 2° "
T03(04) = " 1° - 3° "
T03(05) = " 1° - 4° "
T03(06) = " 1° - 5° "
T03(07) = " 2° - 3° "
T03(08) = " 2° - 4° "
T03(09) = " 2° - 5° "
T03(10) = " 3° - 4° "
T03(11) = " 3° - 5° "
T03(12) = " 4° - 5° "
Call InitTabella(T03,RGB(251,125,000),,02)
For r = 01 To 11
If r = 11 Then r = 12
Dim Dis01,Dis02,Dis03,Dis04,Dis05,Dis06,Dis07,Dis08,Dis09,Dis10
Dis01 = Distanza(Estratto(es,r,01),Estratto(es,r,02))
Dis02 = Distanza(Estratto(es,r,01),Estratto(es,r,03))
Dis03 = Distanza(Estratto(es,r,01),Estratto(es,r,04))
Dis04 = Distanza(Estratto(es,r,01),Estratto(es,r,05))
Dis05 = Distanza(Estratto(es,r,02),Estratto(es,r,03))
Dis06 = Distanza(Estratto(es,r,02),Estratto(es,r,04))
Dis07 = Distanza(Estratto(es,r,02),Estratto(es,r,05))
Dis08 = Distanza(Estratto(es,r,03),Estratto(es,r,04))
Dis09 = Distanza(Estratto(es,r,03),Estratto(es,r,05))
Dis10 = Distanza(Estratto(es,r,04),Estratto(es,r,05))
ReDim V03(12)
V03(01) = NomeRuota(r)
V03(02) = StringaEstratti(es,r)
V03(03) = Dis01
V03(04) = Dis02
V03(05) = Dis03
V03(06) = Dis04
V03(07) = Dis05
V03(08) = Dis06
V03(09) = Dis07
V03(10) = Dis08
V03(11) = Dis09
V03(12) = Dis10
Call AddRigaTabella(V03,,,04,,01)
Call SetColoreCella(01,RGB(207,207,207))
Call SetColoreCella(02,RGB(239,239,239))
Call SetColoreCella(03,vbYellow)
Call SetColoreCella(04,vbYellow)
Call SetColoreCella(05,vbYellow)
Call SetColoreCella(06,vbYellow)
Call SetColoreCella(07,vbYellow)
Call SetColoreCella(08,vbYellow)
Call SetColoreCella(09,vbYellow)
Call SetColoreCella(10,vbYellow)
Call SetColoreCella(11,vbYellow)
Call SetColoreCella(12,vbYellow)
Dim x09,x10
For x09 = 03 To 11
For x10 = x09 + 01 To 12
If V03(x09) = V03(x10) Then Call SetColoreCella((x09),RGB(223,000,223),05)
If V03(x10) = V03(x09) Then Call SetColoreCella((x10),RGB(223,000,223),05)
Next
Next
Next
Call CreaTabella()
'--------------------------------------------------------------------------------------------------
Call Scrivi(" Differenze Matematiche tra gli estratti ",01,,,,04)
ReDim T04(12)
T04(01) = " Ruota "
T04(02) = " Estratti Ruota "
T04(03) = " 1° - 2° "
T04(04) = " 1° - 3° "
T04(05) = " 1° - 4° "
T04(06) = " 1° - 5° "
T04(07) = " 2° - 3° "
T04(08) = " 2° - 4° "
T04(09) = " 2° - 5° "
T04(10) = " 3° - 4° "
T04(11) = " 3° - 5° "
T04(12) = " 4° - 5° "
Call InitTabella(T04,RGB(251,125,000),,02)
For r = 01 To 11
If r = 11 Then r = 12
Dim Dif01,Dif02,Dif03,Dif04,Dif05,Dif06,Dif07,Dif08,Dif09,Dif10
Dif01 = Differenza(Estratto(es,r,01),Estratto(es,r,02))
Dif02 = Differenza(Estratto(es,r,01),Estratto(es,r,03))
Dif03 = Differenza(Estratto(es,r,01),Estratto(es,r,04))
Dif04 = Differenza(Estratto(es,r,01),Estratto(es,r,05))
Dif05 = Differenza(Estratto(es,r,02),Estratto(es,r,03))
Dif06 = Differenza(Estratto(es,r,02),Estratto(es,r,04))
Dif07 = Differenza(Estratto(es,r,02),Estratto(es,r,05))
Dif08 = Differenza(Estratto(es,r,03),Estratto(es,r,04))
Dif09 = Differenza(Estratto(es,r,03),Estratto(es,r,05))
Dif10 = Differenza(Estratto(es,r,04),Estratto(es,r,05))
ReDim V04(12)
V04(01) = NomeRuota(r)
V04(02) = StringaEstratti(es,r)
V04(03) = Dif01
V04(04) = Dif02
V04(05) = Dif03
V04(06) = Dif04
V04(07) = Dif05
V04(08) = Dif06
V04(09) = Dif07
V04(10) = Dif08
V04(11) = Dif09
V04(12) = Dif10
Call AddRigaTabella(V04,,,04,,01)
Call SetColoreCella(01,RGB(207,207,207))
Call SetColoreCella(02,RGB(239,239,239))
Call SetColoreCella(03,vbCyan)
Call SetColoreCella(04,vbCyan)
Call SetColoreCella(05,vbCyan)
Call SetColoreCella(06,vbCyan)
Call SetColoreCella(07,vbCyan)
Call SetColoreCella(08,vbCyan)
Call SetColoreCella(09,vbCyan)
Call SetColoreCella(10,vbCyan)
Call SetColoreCella(11,vbCyan)
Call SetColoreCella(12,vbCyan)
Dim x11,x12
For x11 = 03 To 11
For x12 = x11 + 01 To 12
If V04(x11) = V04(x12) Then Call SetColoreCella((x11),RGB(150,075,075),05)
If V04(x12) = V04(x11) Then Call SetColoreCella((x12),RGB(150,075,075),05)
Next
Next
Next
Call CreaTabella()
'--------------------------------------------------------------------------------------------------
Call Scrivi(" Pari - Dispari ",01,,,,04)
ReDim T05(09)
T05(01) = " Ruota "
T05(02) = " Estratti Ruota "
T05(03) = " 1° "
T05(04) = " 2° "
T05(05) = " 3° "
T05(06) = " 4° "
T05(07) = " 5° "
T05(08) = " PARI "
T05(09) = " DISPARI "
Call InitTabella(T05,RGB(251,125,000),,02)
For r = 01 To 11
If r = 11 Then r = 12
Dim PD01,PD02,PD03,PD04,PD05
Dim PT,DT
If pari(Estratto(es,r,01))Then
PD01 = "P":PT = PT + 01
Else
PD01 = "D":DT = DT + 01
End If
If pari(Estratto(es,r,02))Then
PD02 = "P":PT = PT + 01
Else
PD02 = "D":DT = DT + 01
End If
If pari(Estratto(es,r,03))Then
PD03 = "P":PT = PT + 01
Else
PD03 = "D":DT = DT + 01
End If
If pari(Estratto(es,r,04))Then
PD04 = "P":PT = PT + 01
Else
PD04 = "D":DT = DT + 01
End If
If pari(Estratto(es,r,05))Then
PD05 = "P":PT = PT + 01
Else
PD05 = "D":DT = DT + 01
End If
Dim PTOT,DTOT
PTOT = PTOT + PT
DTOT = DTOT + DT
ReDim V05(09)
V05(01) = NomeRuota(r)
V05(02) = StringaEstratti(es,r)
V05(03) = PD01
V05(04) = PD02
V05(05) = PD03
V05(06) = PD04
V05(07) = PD05
V05(08) = PT
V05(09) = DT
Call AddRigaTabella(V05,,,04,,01)
Call SetColoreCella(01,RGB(207,207,207))
Call SetColoreCella(02,RGB(239,239,239))
If PD01 = "D" Then
Call SetColoreCella(03,vbYellow)
Else
Call SetColoreCella(03,vbCyan)
End If
If PD02 = "D" Then
Call SetColoreCella(04,vbYellow)
Else
Call SetColoreCella(04,vbCyan)
End If
If PD03 = "D" Then
Call SetColoreCella(05,vbYellow)
Else
Call SetColoreCella(05,vbCyan)
End If
If PD04 = "D" Then
Call SetColoreCella(06,vbYellow)
Else
Call SetColoreCella(06,vbCyan)
End If
If PD05 = "D" Then
Call SetColoreCella(07,vbYellow)
Else
Call SetColoreCella(07,vbCyan)
End If
Call SetColoreCella(08,vbCyan)
Call SetColoreCella(09,vbYellow)
PT = 00
DT = 00
Next
Call CreaTabella()
End Sub