I have the following code below and wanted to know how I can fix it.
In
are "rankings" and so there are some information in
is equally ranked, namely 172 onwards
When I perform an index/ match below, with the rankings numbers in Sheet 2, the repeated ranks do not populate. All I am getting is the first ranking result for the rank of 172, repeated until 186.
Does anyone have any suggestions on how I can improve/ correct this error?
------
Dim x As Range
Dim x1 As Range
Dim y As Worksheet
Set x = Worksheets("sheet1").Range("A7:A186")
Set x1 = Worksheets("sheet1").Range("I7:I186")
Set y = Worksheets("sheet2")
Dim i As Integer
For i = 146 To 325
y.Cells(i, 27).Value = Application.WorksheetFunction.Index(x1, Application.WorksheetFunction.Match(y.Cells(i, 26).Value, x, 0))
Next i
End Sub
Thanks
Tony
Bookmarks