marionmccaleb
New Member
- Joined
- Sep 26, 2006
- Messages
- 24
I have a long list of names some of which are duplicated once---I want to delete the records of both of these names (not just one which the Filter function will do). How can I do this?
You're almost right. The file is actually the workbook. (They mean the same thing butI finally figured out a 'worksheet' was just the file containing the info I want to process
Marion,Thanks for your suggestion Erik but since I'm not a programmer I think I'll stick ...
Option Explicit
Sub test()
Dim i As Long
Dim rng As Range
Set rng = Cells(1, 1)
For i = 3 To 2000
Set rng = Union(rng, Cells(i * 2, 1))
Next i
MsgBox rng.Cells.Count
rng = 1
rng.Select
End Sub