+ Reply to Thread
Results 1 to 7 of 7

Insert blank rows in a large data series

Hybrid View

  1. #1
    Registered User
    Join Date
    12-30-2015
    Location
    england
    MS-Off Ver
    2010
    Posts
    74

    Insert blank rows in a large data series

    I need to insert two blank rows between each data for the whole series. Ofcourse I can do this manually, which will take a while. Is there any other quick method to insert fixed no of blank rows between each data set for the wole data series. I have manually added blank rows in attached for the first 3 set of data (two set of two blanks rows each). Can anyone please help?
    Attached Files Attached Files

  2. #2
    Forum Expert Olly's Avatar
    Join Date
    09-10-2013
    Location
    Darlington, UK
    MS-Off Ver
    Excel 2016, 2019, 365
    Posts
    6,284

    Re: Insert blank rows in a large data series

    This will do it:

    Sub foo()
        Dim l As Long
        For l = Cells(Rows.Count, 1).End(xlUp).Row To 2 Step -1
            Cells(l, 1).Offset(1, 0).Resize(2).EntireRow.Insert
        Next l
    End Sub
    let Source = #table({"Question","Thread", "User"},{{"Answered","Mark Solved", "Add Reputation"}}) in Source

    If I give you Power Query (Get & Transform Data) code, and you don't know what to do with it, then CLICK HERE

    Walking the tightrope between genius and eejit...

  3. #3
    Registered User
    Join Date
    12-30-2015
    Location
    england
    MS-Off Ver
    2010
    Posts
    74

    Re: Insert blank rows in a large data series

    Could you explain this bit please. How do I include this in sheet

  4. #4
    Forum Expert Olly's Avatar
    Join Date
    09-10-2013
    Location
    Darlington, UK
    MS-Off Ver
    Excel 2016, 2019, 365
    Posts
    6,284

    Re: Insert blank rows in a large data series

    Activate the worksheet where you want to insert blank rows.

    Press Alt-F11 to open the Visual Basic Editor.

    Click Insert > Module. In the module which appears, paste the code from post #2.

    Click File > Close and return to Microsoft Excel.

    Press Alt-F8 to open the Macro dialog.

    Select macro "foo" then click Run.


    Done.

  5. #5
    Registered User
    Join Date
    12-30-2015
    Location
    england
    MS-Off Ver
    2010
    Posts
    74

    Re: Insert blank rows in a large data series

    Awesome Thank a lot!

  6. #6
    Registered User
    Join Date
    12-30-2015
    Location
    england
    MS-Off Ver
    2010
    Posts
    74

    Re: Insert blank rows in a large data series

    Quick question , If I want to insert 3 blank rows, can I do that changing no to 3 above?

  7. #7
    Forum Expert Olly's Avatar
    Join Date
    09-10-2013
    Location
    Darlington, UK
    MS-Off Ver
    Excel 2016, 2019, 365
    Posts
    6,284

    Re: Insert blank rows in a large data series

    Yes, to insert 3 blank rows, change the 'resize' value:

            Cells(l, 1).Offset(1, 0).Resize(3).EntireRow.Insert

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Replies: 11
    Last Post: 07-30-2015, 12:35 PM
  2. [SOLVED] insert blank rows every nth row and copy down data to fill blank rows
    By surpass in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 10-06-2014, 02:55 PM
  3. Replies: 4
    Last Post: 09-16-2014, 10:48 AM
  4. How to create a macro to insert blank rows and copy data into blank rows?
    By zodiack101 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 10-29-2013, 01:18 PM
  5. [SOLVED] Macro to insert blank rows so that the total number of rows with data is equal to 1021
    By nsm1411 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 03-07-2013, 10:25 AM
  6. I need to insert blank rows into a large spreadsheet.
    By naffie in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 01-12-2013, 07:18 PM
  7. [SOLVED] Cycle Through A Series of Worksheets & Insert Rows, Then Special Paste Data
    By DDM64 in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 12-26-2012, 10:45 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1