Class Script
Sub Main
Dim Nu(5) As Integer, Ru(1) As Integer, cad(5) As Integer, dec(5) As Integer, fig(5) As Integer, gem(5) As Integer, dia(5) As Integer
Dim T() As String, V() As String
Dim Ini As Integer, Fin As Integer, Es As Integer, p As Integer, r As Integer, da As String, p1 As Integer, p2 As Integer
Dim par As Integer, dis As Integer
Dim aa As String = "", bb As String = "", cc As String = "", dd As String = "", ff As String = "", pp As String = ""
Dim diaD As String = "", amboCad As String = "", ambodec As String = "", amboFig As String = "", ambodiamet As String = "", ambosimm As String = "", ambovert As String = "", amboRad As String = "", ambocons As String = ""
Dim VetC() As Integer, VetF() As Integer, VetD() As Integer, VetDD() As Integer
Ini = EstrazioniArchivio() - 10
Fin = EstrazioniArchivio()
For Es = Fin To Ini Step -1
Scrivi(GetInfoEstrazione(Es) & vbTab & "**** Script By Mike58 ****", True,,, ColoreRosso, 150)
T = {"", "Ruota", "Estratti", "Ambo Cadenza", "Ambo Decina", "Ambo Figura", "Tipo Fig", "Gemello", "NumPrimi", "amboCons", "NumPari", "NumDispari", "AmboDiam", "AmboSimm", "AmboVert", "DiamD", "AmboRad"}
Call InitTabella(T)
par = 0 : dis = 0
For r = 1 To 11
For p = 1 To 5
Nu(p) = Estratto(Es, r, p)
cad(p) = Cadenza(Nu(p))
dec(p) = DecinaNaturale(Nu(p))
fig(p) = Figura(Nu(p))
gem(p) = Gemello(Nu(p))
If Gemello(Nu(p)) Then ff = ff & Nu(p) & " "
If IsPrimo(Nu(p)) Then pp = pp & Nu(p) & " "
da = SommaEstratti(Es, r)
If IsPari(Nu(p)) Then par = par + 1
If IsDispari(Nu(p)) Then dis = dis + 1
Ru(1) = r
Next
If NumeriRipetutiRilevatiV(cad, VetC) Then
aa = StringaNumeri(VetC)
Else
aa = "--"
End If
If NumeriRipetutiRilevatiV(dec, VetD) Then
bb = StringaNumeri(VetD)
Else
bb = "--"
End If
If NumeriRipetutiRilevatiV(fig, VetF) Then
cc = StringaNumeri(VetF)
Else
cc = "--"
End If
If NumeriRipetutiRilevatiV(dia, VetDD) Then
dd = StringaNumeri(VetF)
Else
dd = "--"
End If
For p1 = 1 To 4
For p2 = p1 + 1 To 5
If Cadenza(Nu(p1)) = Cadenza(Nu(p2)) Then amboCad = amboCad & Nu(p1) & "-" & Nu(p2) & " "
If Distanza(Nu(p1), Nu(p2)) = 45 Then ambodiamet = ambodiamet & Nu(p1) & "-" & Nu(p2) & " "
If Distanza(Nu(p1), Nu(p2)) = 30 Then ambosimm = ambosimm & Nu(p1) & "-" & Nu(p2) & " "
If (Nu(p1)) = Vertibile(Nu(p2)) Then ambovert = ambovert & Nu(p1) & "-" & Nu(p2) & " "
If (Nu(p1)) = DiametraleInDecina(Nu(p2)) Then diaD = diaD & Nu(p1) & "-" & Nu(p2) & " "
If DecinaNaturale(Nu(p1)) = DecinaNaturale(Nu(p2)) Then ambodec = ambodec & Nu(p1) & "-" & Nu(p2) & " "
If Figura(Nu(p1)) = Figura(Nu(p2)) Then amboFig = amboFig & Nu(p1) & "-" & Nu(p2) & " "
If Radicale(Nu(p1)) And Radicale(Nu(p2)) And Radicale(Nu(p1)) = Radicale(Nu(p2)) And Radicale(Nu(p1)) > 0 And Radicale(Nu(p2)) > 0 Then amboRad = amboRad & Nu(p1) & "-" & Nu(p2) & " "
'If Radicale(a) And Radicale(b) And Radicale(a) = Radicale(b) Then
If Differenza(Nu(p1), Nu(p2)) = 1 Then ambocons = ambocons & Nu(p1) & "-" & Nu(p2) & " "
Next
Next
V = {"", NomeRuota(r, True), StringaEstratti(Es, r), amboCad, ambodec, amboFig, cc, ff, pp, ambocons, par, dis, ambodiamet, ambosimm, ambovert, diaD, amboRad}
Call AddRigaTabella(V)
ff = ""
pp = ""
da = ""
par = 0
dis = 0
diaD = ""
amboCad = ""
ambodec = ""
amboFig = ""
ambodiamet = ""
ambosimm = ""
ambovert = ""
amboRad = ""
ambocons = ""
Next
CreaTabella()
Next
End Sub
End Class