问题
I wanted to remove only the row that is identified as duplicate with some condition. But, the problem I am facing right now is I am getting all the rows below the duplicate row getting deleted with the coding I have. Hence, I loose all the entries that are below the duplicate row in a different table. Hope you get my problem.
Please suggest a proper VBA code for this situation. I have given the code that I am using.
Private Sub CommandButton2_Click()
Dim rng As Range
Set rng = ThisWorkbook.Sheets("Sheet1").UsedRange
rng.RemoveDuplicates Columns:=1, Header:=xlYes
End Sub
Sample Table Image - Blue Rectangle indicates the region boundaries (only within row 15 column E rectangle duplicate removal should happen
来源:https://stackoverflow.com/questions/65630126/how-to-remove-only-the-duplicate-row-instead-of-removing-all-the-rows-that-follo