+ Reply to Thread
Results 1 to 3 of 3

Insert Rows and copy format and formula

  1. #1
    Valued Forum Contributor
    Join Date
    01-18-2007
    Location
    Georgia
    MS-Off Ver
    2010
    Posts
    4,434

    Insert Rows and copy format and formula

    Hello:

    Please refer to attached file.

    I need a VB Code to do the follwowing.

    Need to insert rows by asking
    Insert row after
    How many rows to be inserted
    For Example : Start to insert after row3 and add 10 rows


    Then would need to copy the corresponding cell in column C and D down to the inserted rows with format and formula

    For Example :
    C3 = Sheet2!C3, D3 = Sheet2!D3
    C4 = Sheet2!C4, D4 = Sheet2!D4
    C3 = Sheet2!C5, D5 = Sheet2!D5
    C3 = Sheet2!C6, D6 = Sheet2!D6
    C3 = Sheet2!C7, D7 = Sheet2!D7
    and so on...
    Let me know if you have any questions.
    Thanks.
    Riz
    Attached Files Attached Files

  2. #2
    Forum Expert NeedForExcel's Avatar
    Join Date
    03-16-2013
    Location
    Pune, India
    MS-Off Ver
    Excel 2016:2019, MS 365
    Posts
    3,873

    Re: Insert Rows and copy format and formula

    Here!

    Try this -

    Please Login or Register  to view this content.
    File with code attached. Insert Row.xlsm
    Last edited by NeedForExcel; 03-20-2015 at 12:18 AM.
    Cheers!
    Deep Dave

  3. #3
    Valued Forum Contributor
    Join Date
    01-18-2007
    Location
    Georgia
    MS-Off Ver
    2010
    Posts
    4,434

    Re: Insert Rows and copy format and formula

    Hello: msexcelarhome

    Works great...
    One question, assume that i have formula until column EA, then i would need to change the above code as below:
    Please Login or Register  to view this content.
    Is this correct?

    Thanks
    Riz

+ 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. Insert rows and copy formula
    By costin in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 07-05-2013, 10:54 AM
  2. Replies: 0
    Last Post: 05-10-2013, 12:04 PM
  3. Copy and insert rows with contents and format based on specific number
    By fatalcore in forum Excel Programming / VBA / Macros
    Replies: 11
    Last Post: 01-13-2012, 03:38 AM
  4. Insert 2 rows, copy the formula.
    By JennyVBA in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 07-28-2010, 07:35 PM
  5. insert rows needs to copy formula
    By Mark J Kubicki in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 05-09-2006, 11:06 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