|If the data is not sorted, then finding duplicates by comparing each cell only to the cell above it will be coincidental at best. Sorting the data would put the duplicates together.|
If sorting the data "permanently" will be an issue, you can do all of the following within your macro:
1 - Add a column of sequential numbers in Column U
2 - Sort all of the data on Column T
3 - Remove the duplicates using your existing code
4 - Sort the data on Column U to put it back in it's original order
5 - Delete Columns T & U
BTW, the following is not "true":
'Determine the number of items in column T
lastRow = Cells(Rows.Count, 2).End(xlUp).Row
Cells(Rows.Count, 2) refers to Column B, not Column T.
BTW.2 Are you familiar with the use of F8 to single step through your code to watch what it is doing, line by line? Size your VBA window so that you can see your spreadsheet behind it and press F8 repeatedly.
Click Here Before Posting Data or VBA Code ---> How To Post Data or Code.