Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I'm having some problems with the code below. "Range" is
a range name for the items in column A on sheet 2. I want to look in column A on sheet 1 and if there is a match in the range (Column A - sheet 2), then I want to delete the row on Sheet 1 where the match occurs Sheets("1").Activate Dim rngToSearch Dim rngToFind As Range Dim rngFound As Range Set rngToSearch = Sheets("2").Range("Range") For Each rngToFind In rngToSearch Set rngFound = Sheets("1").Cells.Find(rngToFind.Value) Do While Not rngFound Is Nothing rngFound.EntireRow.Delete Set rngFound = Sheets("1").Cells.Find. (rngToFind.Value) Loop Next rngToFind Any help would be greatly appreciated. Thanks........ |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Matching like items | Excel Worksheet Functions | |||
Formula for non matching items | Excel Worksheet Functions | |||
matching items on a range | Excel Discussion (Misc queries) | |||
Matching Items | Excel Worksheet Functions | |||
matching items on 2 sheets | Excel Programming |