Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.misc
|
|||
|
|||
How do I insert 20 rows between each row of text?
I have a two column list of 265 names. I want to insert 20 blank rows between
each name. Is there some easy way to do this? Seems like an easy and somewhat stupid question. Sorry! |
#2
Posted to microsoft.public.excel.misc
|
|||
|
|||
How do I insert 20 rows between each row of text?
Sub InsertRows()
Application.ScreenUpdating = False Dim numRows As Integer Dim r As Long numRows = 20 For r = 265 To 1 Step -1 ActiveSheet.Rows(r + 1).Resize(numRows).EntireRow.Insert Next r Application.ScreenUpdating = True End Sub If not familiar with VBA and macros, see David McRitchie's site for more on "getting started". http://www.mvps.org/dmcritchie/excel/getstarted.htm In the meantime.......... First...create a backup copy of your original workbook. To create a General Module, hit ALT + F11 to open the Visual Basic Editor. Hit CRTL + r to open Project Explorer. Find your workbook/project and select it. Right-click and InsertModule. Paste the code in there. Save the workbook and hit ALT + Q to return to your workbook. Run the macro by going to ToolMacroMacros. You can also assign this macro to a button or a shortcut key combo. Gord Dibben MS Excel MVP On Fri, 2 Feb 2007 14:28:00 -0800, PaigeinFL wrote: I have a two column list of 265 names. I want to insert 20 blank rows between each name. Is there some easy way to do this? Seems like an easy and somewhat stupid question. Sorry! |
#3
Posted to microsoft.public.excel.misc
|
|||
|
|||
How do I insert 20 rows between each row of text?
If you can limit yourself to 254 names
and want an easy way without VBA, then go to Tools Options Custom Lists Import list from cells, and enter $A$1:$A$254 Enter the name at A1 into C1 and select it and 20 blank cells below it. Drag the fill handle down to row 5334. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
How to convert a month to a quarter ...... | New Users to Excel | |||
How can I insert and delete rows within a locked cell range column | Excel Worksheet Functions | |||
How to protect some cells, but able to insert rows elsewhere? | Excel Discussion (Misc queries) | |||
Copy/Paste Rows that Contain Specific Text | Excel Worksheet Functions | |||
can't insert more rows even though not at max rows | Excel Worksheet Functions |