Novità

Macro e lotto piccolo problema chi mi può aiutare per cortesia

TONY@

Advanced Member >PLATINUM PLUS<
Buongiorno un piccolo problema che non riesco a risolvere
la macro mi ordina i numeri cercati in verticale ,io ho bisogno di vederli in orizzontale
se considero solo un uscita estraz...riesco a farli mettere in orizz, ma quando ci sono più uscite tipo 5
allora non si può fare li accavalla i risultati ,non sono molto pratico di macro ,come posso risolvere il problema ?
Vorrei che le estraz..che trova le disponga riga per riga da o5 -s5
in giù a scendere come da esempio 2 sotto.
grazie mille forse e una piccolezza ma non trovo la soluzione

74
64 esempio
90 cosi sono adesso metto solo due colonne di esempio
32
43

20
7
42
40
66
..............................................................................................
esempio 2

74 64 90 32 43 <<<<cosi andrebbero benissimo a scendere
20 7 42 40 66

.................................................................................
H2 I2 J3 K2
10 10 5
5

-----------------------------------------------------------------------------------------------
Sub UNOSOPRA()
Range("O5:Z9").ClearContents

UE = Worksheets("Foglio1").Range("A" & Rows.Count).End(xlUp).Row
Area = Worksheets("Foglio1").Range("A6:AX" & UE)
valore = Range("g4").Value
If [i2] > 50 Then
MsgBox "Digitare N. Colonne (da 2 a 50)"
Range("h2").Select
GoTo Fine
End If
If [h2] = 0 Then
MsgBox "Digitare N. Colonne (da 1 a 49)"
Range("i2").Select
GoTo Fine
End If

If [h2] > [i2] Then
MsgBox "Inizio N. Colonne maggiore di Fine N. Colonne, correggere!"
Range("j2").Select
GoTo Fine
End If

If [J2] = "" Then
MsgBox "digitare inizio riga"
Range("J2").Select
GoTo Fine
End If
If [g4] = "" Then
MsgBox "digitare Numeri da trovare"
Range("K2").Select
GoTo Fine
End If
inizio = [J2]
For RR = inizio To UE
For CC = [h2] To [i2]
If Worksheets("Foglio1").Cells(RR, CC).Value = valore Then

Cells(5, TR + 15).Value = Worksheets("Foglio1").Cells(RR - 1, CC - 8).Value
Cells(6, TR + 15).Value = Worksheets("Foglio1").Cells(RR - 1, CC - 7).Value
Cells(7, TR + 15).Value = Worksheets("Foglio1").Cells(RR - 1, CC - 6).Value
Cells(8, TR + 15).Value = Worksheets("Foglio1").Cells(RR - 1, CC - 5).Value
Cells(9, TR + 15).Value = Worksheets("Foglio1").Cells(RR - 1, CC - 4).Value

TR = TR + 1
If TR = Range("K2").Value Then GoTo esci
End If
Next CC
Next RR
esci:
Fine:
End Sub
 
Si ma è meglio che alleghi il tuo file di esempio altrimenti bisogna ricostruire tutto il scenario
 
Si ma è meglio che alleghi il tuo file di esempio altrimenti bisogna ricostruire tutto il scenario
non me lo fa caricare lo zippato l'estensione file excel non lo accetta nemmeno zip 500 kb
,ho messo la macro credevo bastasse variare qualcosa all'interno della macro non so come devo fare grazie x l'interesse
 
Sub unoAMBI()
Range("O10:ah14").ClearContents

UE = Worksheets("Foglio1").Range("A" & Rows.Count).End(xlUp).Row
Area = Worksheets("Foglio1").Range("A6:AX" & UE)
valore = Range("g4").Value
If [i2] > 50 Then
MsgBox "Digitare N. Colonne (da 2 a 50)"
Range("h2").Select
GoTo Fine
End If
If [h2] = 0 Then
MsgBox "Digitare N. Colonne (da 1 a 49)"
Range("i2").Select
GoTo Fine
End If

If [h2] > [i2] Then
MsgBox "Inizio N. Colonne maggiore di Fine N. Colonne, correggere!"
Range("j2").Select
GoTo Fine
End If

If [J2] = "" Then
MsgBox "digitare inizio riga"
Range("J2").Select
GoTo Fine
End If
If [g4] = "" Then
MsgBox "digitare Numeri da trovare"
Range("K2").Select
GoTo Fine
End If
inizio = [J2]
For RR = inizio To UE
For CC = [h2] To [i2]
If Worksheets("Foglio1").Cells(RR, CC).Value = valore Then

Cells(5, TR + 15).Value = Worksheets("Foglio1").Cells(RR, CC - 8).Value
Cells(6, TR + 15).Value = Worksheets("Foglio1").Cells(RR, CC - 7).Value
Cells(7, TR + 15).Value = Worksheets("Foglio1").Cells(RR, CC - 6).Value
Cells(8, TR + 15).Value = Worksheets("Foglio1").Cells(RR, CC - 5).Value
Cells(9, TR + 15).Value = Worksheets("Foglio1").Cells(RR, CC - 4).Value



TR = TR + 1
If TR = Range("K2").Value Then GoTo esci
End If
Next CC
Next RR
esci:
Fine:
End Sub
 
Nel modulo 121 sostituisci quelle esistenti con queste sotto


Cells(5 + TR, 15).Value = Worksheets("Foglio1").Cells(RR, CC - 8).Value
Cells(5 + TR, 16).Value = Worksheets("Foglio1").Cells(RR, CC - 7).Value
Cells(5 + TR, 17).Value = Worksheets("Foglio1").Cells(RR, CC - 6).Value
Cells(5 + TR, 18).Value = Worksheets("Foglio1").Cells(RR, CC - 5).Value
Cells(5 + TR, 19).Value = Worksheets("Foglio1").Cells(RR, CC - 4).Value
 

Oscar grande va benissimo adesso ho capito il problema io non ci sarei mai arrivato grazie mille​

Cells(10, TR + 15).Value = Worksheets("Foglio1").Cells(RR, CC - 8).Value

Cells(10 + TR, 15).Value = Worksheets("Foglio1").Cells(RR, CC - 8).Value
 

Ultima estrazione Lotto

  • Estrazione del lotto
    giovedì 08 ottobre 2026
    Bari
    74
    62
    12
    61
    09
    Cagliari
    75
    78
    41
    86
    54
    Firenze
    42
    65
    75
    16
    73
    Genova
    47
    50
    31
    80
    49
    Milano
    61
    23
    39
    57
    40
    Napoli
    31
    65
    58
    19
    66
    Palermo
    19
    26
    06
    71
    27
    Roma
    40
    65
    45
    29
    49
    Torino
    24
    67
    45
    64
    48
    Venezia
    35
    61
    62
    19
    13
    Nazionale
    67
    26
    57
    14
    89
    Estrazione Simbolotto
    32
    10
    08
    39
    24
Indietro
Alto