Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
Need to insert blank rows
Hi,
If we have 5000 rows of data and we need to insert a blank row after every row, what would be the best way to do it? Thanks |
#2
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
Need to insert blank rows
Macro.
Something like this: Sub InsertRowAlternate() While ActiveCell < "" Selection.EntireRow.Insert ActiveCell.Offset(2, 0).Range("A1").Select Wend End Sub The "while" part will run down the page until it finds a blank cell; this assumes that you have no blanks in the 5000. Otherwise you can use a for loop, but I wasn't sure if your "5000" was an estimate or an exact number. On Jun 26, 2:29*pm, "Gaurav" wrote: Hi, If we have 5000 rows of data and we need to insert a blank row after every row, what would be the best way to do it? Thanks |
#3
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
Need to insert blank rows
Gaurav wrote:
Hi, If we have 5000 rows of data and we need to insert a blank row after every row, what would be the best way to do it? Thanks One option (Save a copy first!): Assuming there is always data in column A and no blank rows within the 5000, go to the first completely unused column and enter the following in row 1: =IF(A1="",ROW()-COUNTA(A:A)+0.5,ROW()-1) Copy this formula down 10000 rows, select all of your data, including the headers and the new column, then sort by the new column (with "no header row" selected). |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
How do i insert blank rows between data that is thousands of rows | Excel Discussion (Misc queries) | |||
insert blank rows | Excel Discussion (Misc queries) | |||
How can I insert a blank row after every four rows in Excel? | Excel Discussion (Misc queries) | |||
How do I insert blank rows between rows in completed worksheet? | Excel Discussion (Misc queries) | |||
How to quickly insert a blank row every 5 rows? | Excel Discussion (Misc queries) |