Hi anyone helpme to sort out this problem.
I have an Excel sheet with names in Column A, Hours in Column B and
Amount in Column C. What my question is i want to eliminate the
duplicate rows in Column A , mean while B and C should be added to the
unique user row. Is there any macro for that?
Thanks in Advance.Sub CreateSummary()
Dim iLastRow As Long
Dim i As Long
Dim iRow As Long
iLastRow = Cells(Rows.Count, quot;Aquot;).End(xlUp).Row
For i = iLastRow To 2 Step -1
iRow = Application.Match(Cells(i, quot;Aquot;).Value, Columns(1), 0)
If iRow lt; i Then
Cells(iRow, quot;Bquot;).Value = Cells(iRow, quot;Bquot;).Value Cells(i,
quot;Bquot;).Value
Cells(iRow, quot;Cquot;).Value = Cells(iRow, quot;Cquot;).Value Cells(i,
quot;Cquot;).Value
Rows(i).Delete
End If
Next i
End Sub--
HTH
Bob Phillips
(remove nothere from email address if mailing direct)
quot;meendarquot; gt; wrote in message oups.com...
gt; Hi anyone helpme to sort out this problem.
gt;
gt; I have an Excel sheet with names in Column A, Hours in Column B and
gt; Amount in Column C. What my question is i want to eliminate the
gt; duplicate rows in Column A , mean while B and C should be added to the
gt; unique user row. Is there any macro for that?
gt;
gt; Thanks in Advance.
gt;
- Jun 22 Fri 2007 20:37
Eliminate Duplicate Rows
close
全站熱搜
留言列表
發表留言