Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Post your code.
If you are deleting rows, it should not find any more values. If you are trying to start from a certain row and only process forward (down), then you need to put in a check for the location of the found cell and possibly alter the search parameters prior. Explain how it can delete all the instances of the target, yet then delete two more rows? -- Regards, Tom Ogilvy "JMay" wrote in message news:uJG%b.13272$TT5.3326@lakeread06... Bob: Based on your macro I set up a scenario and gave it a try. It work perfectly, only somehow [at the end] it goes back to the beginning of the range and deletes two additional rows, erroneously. Can you comment/alter code to eliminate? TIA, "Bob Phillips" wrote in message ... Why didn't you say? Dim oFound As Range Dim firstaddress Set oFound = Cells.Find("ADDRESS") If Not oFound Is Nothing Then firstaddress = oFound.Address Do oFound.Offset(1, 0).Resize(3, 1).EntireRow.Delete Set oFound = Cells.FindNext(oFound) Loop While Not oFound Is Nothing And firstaddress < oFound.Address End If -- HTH Bob Phillips ... looking out across Poole Harbour to the Purbecks (remove nothere from the email address if mailing direct) "alexm999 " wrote in message ... How do I loop it, I have the word ADDRESS in my spreadsheet showing up about 100 times. I'd like to scan through the whole spreadsheet and delete 3 rows after each word ADDRESS --- Message posted from http://www.ExcelForum.com/ |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Macro for deleting rows and serialising the remaing rows | Links and Linking in Excel | |||
Macro for deleting rows and serialising the remaing rows | Setting up and Configuration of Excel | |||
Macro for deleting rows and serialising the remaing rows | Excel Worksheet Functions | |||
Help!! I have problem deleting 2500 rows of filtered rows!!!! | Excel Discussion (Misc queries) | |||
deleting hidden rows so i can print only the rows showing?????? | Excel Worksheet Functions |