+ Reply to Thread
Results 1 to 4 of 4

Copy and Paste rows

  1. #1
    Registered User
    Join Date
    04-22-2009
    Location
    Boston
    MS-Off Ver
    Excel 2013
    Posts
    68

    Copy and Paste rows

    Hi,

    I want to copy and paste row in sheet 3 to the row in sheet 1.
    Since the row no is a variable, i m having difficulty in writing the right formula.
    Please help.

    Please Login or Register  to view this content.
    Above code doesn't work
    Last edited by kapilrakh; 11-13-2009 at 04:06 PM.

  2. #2
    Forum Contributor
    Join Date
    05-09-2009
    Location
    London, England
    MS-Off Ver
    Excel 2007
    Posts
    315

    Re: Copy and Paste rows

    Hi Kapilrakh

    Try this:

    Please Login or Register  to view this content.

  3. #3
    Registered User
    Join Date
    04-22-2009
    Location
    Boston
    MS-Off Ver
    Excel 2013
    Posts
    68

    Re: Copy and Paste rows

    Hey mojo,

    Thanks for your reply. But your code copies the values cell wise instead of the entire row. It take a lot of time plus I will have to repeat this code for every column. Please put the code to copy and paste entire row. The row no is a variable

  4. #4
    Forum Contributor
    Join Date
    05-09-2009
    Location
    London, England
    MS-Off Ver
    Excel 2007
    Posts
    315

    Re: Copy and Paste rows

    To copy a row instead of the cell substitute

    Cells(varRowSource, 1).Select and Cells(varRowTarget, 1).Select

    for

    Row(varRowSource).Select and Row(varRowTarget).Select

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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