Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Select and Delete Every Other Row in Excel Sheet
Hello all
Need to find a Script that would Delete every other row in Excel say starting at Row A1 to Row A100 it would delete A2,A4,A6 and so on Thanks Scott |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Select and Delete Every Other Row in Excel Sheet
hi
somthing like this, delete every scecond row Sub DeleteRows() Dim i As Long, lastrow As Long lastrow = Cells(Rows.Count, "A").End(xlUp).Row For i = 2 To lastrow Step 2 Rows(i).Delete Next End Sub Regards Yngve |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Select and Delete Every Other Row in Excel Sheet
for i = 100 to 1 step -2
rows(i).Delete Next -- Regards, Tom Ogilvy "Sawyer" wrote: Hello all Need to find a Script that would Delete every other row in Excel say starting at Row A1 to Row A100 it would delete A2,A4,A6 and so on Thanks Scott |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
Select and Delete Every Other Row in Excel Sheet
I like this one straight to the point and easy to change
"Tom Ogilvy" wrote in message ... for i = 100 to 1 step -2 rows(i).Delete Next -- Regards, Tom Ogilvy "Sawyer" wrote: Hello all Need to find a Script that would Delete every other row in Excel say starting at Row A1 to Row A100 it would delete A2,A4,A6 and so on Thanks Scott |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Help! Cannot select option buttons when Excel sheet is protected. | Excel Discussion (Misc queries) | |||
How do I select several control buttons at once on an Excel sheet | Excel Discussion (Misc queries) | |||
How do I select all odd-numbered rows in huge excel sheet? | Excel Discussion (Misc queries) | |||
Select and Insert one sheet from a multisheet excel template | Excel Discussion (Misc queries) | |||
Select certain rows of sheet & delete the rest | Excel Programming |