I have a spreadsheet with transactions by customers. I want make a list of them in another section of the spreadsheet without duplicating their names.
I have the following code:
Code
On Error Resume Next
Dim Startrow, Endrow, i, j
Application.ScreenUpdating = False
Startrow = Val(Application.InputBox("First Row number"))
Endrow = Val(Application.InputBox("Last Row number"))
If Startrow > Endrow Then
MsgBox "Start Row is past the End Row, try again"
Exit Sub
End If
j = ActiveCell
For i = Endrow To Startrow Step -1
If Cells(i, 10).Value <> Cells(i, 10).Offset(-1, 0) Then
ActiveCell.Value = Cells(1, 10)
End If
j = j + 1
Next
Application.ScreenUpdating = True
Display More
The problem I have having is moving the destination line down one line. How do I do that with this. I am using the j variable to represent the destination cell.
Thanks