Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.misc
|
|||
|
|||
Macro that deletes rows from cell containing End to end of data.
MS OS XP:
Excel 2000: Need a macro that deletes all rows from the end of data up to a cell in Colum A that contains the word End. Example: If cell A(150) = End Then Delete all rows from the end of data up to and including row 150. Thanks in advanced, -- Richard |
#2
Posted to microsoft.public.excel.misc
|
|||
|
|||
Macro that deletes rows from cell containing End to end of data.
Sub DeleteRowsAfterWordEnd()
Dim iRow As Long Dim iCol As Long iRow = 1 iCol = 1 While Cells(iRow, iCol) < "End" iRow = iRow + 1 If iRow 65536 Then Exit Sub End If Wend Rows(Format(iRow, "0") & ":65536").Delete End Sub |
#3
Posted to microsoft.public.excel.misc
|
|||
|
|||
Macro that deletes rows from cell containing End to end of data.
try this simple ditty
sub delrows() fr=columns(1).find("End").row lr=cells(rows.count,"a").end(xlup).row rows(fr & ":" & lr).delete end sub -- Don Guillett Microsoft MVP Excel SalesAid Software "Richard" wrote in message ... MS OS XP: Excel 2000: Need a macro that deletes all rows from the end of data up to a cell in Colum A that contains the word End. Example: If cell A(150) = End Then Delete all rows from the end of data up to and including row 150. Thanks in advanced, -- Richard |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
shared file adds or deletes rows | Excel Discussion (Misc queries) | |||
Macro that deletes every third row....+ | Excel Discussion (Misc queries) | |||
Copy to in Adv filter deletes data in lower rows | Excel Discussion (Misc queries) | |||
Renaming and saving workbooks but macro still deletes | Excel Worksheet Functions | |||
WHEN DOWNLOADING A TEXTFILE EXCEL DELETES BLANK ROWS - STOP THIS? | Excel Worksheet Functions |