Good day friends,
I'm using this code to select the 10 lowest values and give them a ranking from 1 to 10.
My query;
Is it possible to modify this code so that it will give the lowest values the opposite ranking from which it is now. (Please take a look at the example sheet).
Thank you for any help offered,
Robert
Sub TST()
Dim A As Integer, B As Integer
For A = 1 To 15
For B = 1 To 10
If Range("B1").Cells(A, 1) = Application.WorksheetFunction.Small(Range("B1:B15"), B) Then
With Range("B1")
.Offset(A - 1, 1) = B
End With
Exit For
End If
Next B
Next A
End Sub
Bookmarks