Ranking

Hello tout le monde, effectivement il y avait d autre cibles je vous ai envoyé 250personnes mais en réalité ils sont + de 1000 personnes d'où l'écart a mon avis

Svp juste un dernier point j'ai fini par réalisé le fichier mais je n'arrive toujours pas à faire un rang unique car si j'ai deux valeurs qui ont la meme somme elle m affiche levmeme rang jai mis la condition dans le fichier excel.

Merci encore une fois.

6classeur4.xlsx (46.84 Ko)

Salut Medysquall,

sauf erreur...

'
Application.EnableEvents = False
Application.ScreenUpdating = False
'
iRow = Cells(Rows.Count, 9).End(xlUp).Row
Range("A2:I" & iRow).Sort key1:=Range("I2"), order1:=xlAscending
'
iStart = 2
iStop = 0
For x = 2 To iRow
    If Cells(x, 9) = Cells(x - 1, 9) And x < iRow Then
        iStop = x
    Else
        If x = iRow And Cells(x, 9) = Cells(x - 1, 9) Then iStop = x
        If iStop - iStart > 0 Then
            Range("A" & iStart & ":I" & iStop).Sort key1:=Range("D" & iStart), order1:=xlDescending, key2:=Range("C" & iStart), order2:=xlDescending, key3:=Range("B" & iStart), order3:=xlDescending
            For y = 0 To (iStop - iStart)
                Cells(iStart + y, 9) = Cells(iStart, 9) + y
            Next
        End If
        iStart = x
    End If
Next
'
Application.ScreenUpdating = True
Application.EnableEvents = True
'

A+

11rankingbis.xlsm (60.67 Ko)

Re,

et je me demande si ceci n'est pas encore meilleur!

'
Application.EnableEvents = False
Application.ScreenUpdating = False
'
iRow = Cells(Rows.Count, 9).End(xlUp).Row
Range("A2:I" & iRow).Sort key1:=Range("B2"), order1:=xlDescending
Range("A2:I" & iRow).Sort key1:=Range("I2"), order1:=xlAscending, key2:=Range("D2"), order2:=xlDescending, key3:=Range("C2"), order3:=xlDescending
For y = 2 To iRow
    Cells(y, 9) = y - 1
Next
'
Application.ScreenUpdating = True
Application.EnableEvents = True
'

A+

Merci curulis, dites a part vba il n y a pas une formule qui prend en charge cette condition avec la fonction rang ?

Rechercher des sujets similaires à "ranking"