Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Deleting rows from all sheets in an array?
I am trying to delete the same specified rows from a each sheet within a
collection of sheets in a workbook. Using code analogous to the following, I'm getting a error. If this is incorrect, is there a way to do it without actually "selecting" the different sheets? Sheets(Array("A", "B","C","D","E","F") ).Rows("5:10").Delete Thanks |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Deleting rows from all sheets in an array?
Hi AVR
Try this Dim sh As Worksheet For Each sh In Sheets(Array("A", "B", "C", "D", "E", "F")) sh.Rows("5:10").Delete Next sh -- Regards Ron de Bruin http://www.rondebruin.nl/tips.htm "AVR" wrote in message ... I am trying to delete the same specified rows from a each sheet within a collection of sheets in a workbook. Using code analogous to the following, I'm getting a error. If this is incorrect, is there a way to do it without actually "selecting" the different sheets? Sheets(Array("A", "B","C","D","E","F") ).Rows("5:10").Delete Thanks |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Macro for deleting rows and serialising the remaing rows | Links and Linking in Excel | |||
Deleting rows, cuts and pastes affected tabbed sheets | Excel Discussion (Misc queries) | |||
inserting deleting rows?how do i get the other sheets to do the sa | Excel Discussion (Misc queries) | |||
combining cells and array from different sheets into an array to pass to IRR() | Excel Discussion (Misc queries) | |||
Updating, Deleting and inserting rows over two Excel Sheets | Excel Worksheet Functions |