+ Reply to Thread
Results 1 to 8 of 8

Macro that copies new data from the bottom of a range to another sheet

  1. #1
    Registered User
    Join Date
    06-21-2017
    Location
    Canada
    MS-Off Ver
    2016
    Posts
    9

    Cool Macro that copies new data from the bottom of a range to another sheet

    I am a newbie to macros and know nothing

    I have two workbooks with the same data ranges. One of them updates with new rows of data constantly which then needs to be copied and pasted into the other workbooks data. I need to create a macro that copies the data from where the new data starts (in the workbook that updates) and pastes it in the other workbook sheet at the end of the old data.

    Is it possible to create macros that grab from one workbook and paste in another?

    If this macro is possible could I add a function that drags down a vlookup formula at the far right of the data to the bottom of the new data (just for maximum efficiency)

    Thanks

  2. #2
    Forum Guru xladept's Avatar
    Join Date
    04-14-2012
    Location
    Pasadena, California
    MS-Off Ver
    Excel 2003,2010
    Posts
    12,378

    Re: Macro that copies new data from the bottom of a range to another sheet

    Seems rather straightforward

    Attach a sample workbook. Make sure there is just enough data to demonstrate your need. Include a BEFORE sheet and an AFTER sheet in the workbook if needed to show the process you're trying to complete or automate. Make sure your desired results are shown, mock them up manually if necessary.

    Remember to desensitize the data.

    Click on GO ADVANCED and then scroll down to Manage Attachments to open the upload window.
    If I've helped you, please consider adding to my reputation - just click on the liitle star at the left.

    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~(Pride has no aftertaste.)

    You can't do one thing. XLAdept

    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~aka Orrin

  3. #3
    Registered User
    Join Date
    06-21-2017
    Location
    Canada
    MS-Off Ver
    2016
    Posts
    9

    Talking Re: Macro that copies new data from the bottom of a range to another sheet

    Attached is a sample version of the type of process I need

    for ease I included the auto-update data in the same workbook in a different sheet even though it would be an entirely different workbook.

    what I need is
    -the new data from auto-update sheet to be pasted to the bottom of the unupdated sheet and then I need the vlookup in the furthest column to be extended down to the bottom where the new data has been pasted

    - I need to do this because the actual data I get updates frequently in mass and the reason I cant just directly use the auto updated workbook is because a program actually has to be run in
    order to generate that sheet for one time use. (also why I cant just use any functions I know of)

    Any help is appreciated thanks
    Attached Files Attached Files

  4. #4
    Forum Guru xladept's Avatar
    Join Date
    04-14-2012
    Location
    Pasadena, California
    MS-Off Ver
    Excel 2003,2010
    Posts
    12,378

    Re: Macro that copies new data from the bottom of a range to another sheet

    Hi YeetBoyGenius,

    Try this:

    Please Login or Register  to view this content.
    *Thanks for the rep!

    We'll have to be more specific when setting the sheet names when they're in different books
    but, if you already know how to do that, you're all set else give me some book names and
    I'll add the code
    Last edited by xladept; 06-22-2017 at 02:16 PM. Reason: Better Solution - Copy Length Fix

  5. #5
    Registered User
    Join Date
    06-21-2017
    Location
    Canada
    MS-Off Ver
    2016
    Posts
    9

    Re: Macro that copies new data from the bottom of a range to another sheet

    It works but the only problem is that the whole entire autoupdated sheet copies to the bottom of the unupdated sheet when I only want the new data starting from project ID 16 in autoupdate to be copied to the bottom of the other. EDIT I FIXED THE COPY LENGTH PROBLEM

    The actual data has to go from "Book1" in sheet "Project Requests Updated (64)" into "New PSFs Approved" in sheet "Project_Requests_Updated (37)"
    Last edited by yeetboygenius; 06-22-2017 at 01:52 PM.

  6. #6
    Forum Guru xladept's Avatar
    Join Date
    04-14-2012
    Location
    Pasadena, California
    MS-Off Ver
    Excel 2003,2010
    Posts
    12,378

    Re: Macro that copies new data from the bottom of a range to another sheet

    Replace the Set line with these two Set lines and let me know:

    Please Login or Register  to view this content.

    *See if you fixed the copy-length the same way I did
    Last edited by xladept; 06-22-2017 at 02:17 PM.

  7. #7
    Registered User
    Join Date
    06-21-2017
    Location
    Canada
    MS-Off Ver
    2016
    Posts
    9

    Re: Macro that copies new data from the bottom of a range to another sheet

    yup I did it the same way. Thanks so much for your help!!!

  8. #8
    Forum Guru xladept's Avatar
    Join Date
    04-14-2012
    Location
    Pasadena, California
    MS-Off Ver
    Excel 2003,2010
    Posts
    12,378

    Re: Macro that copies new data from the bottom of a range to another sheet

    You're welcome and it was fun!

    If that takes care of your original question, please select Thread Tools from the menu link above and mark this thread as SOLVED. Thanks.

+ 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. [SOLVED] Macro that copies a formula to another sheet and copies data at same time
    By Newbienewbster0932 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 05-26-2017, 02:49 PM
  2. Macro that selects a range of data from one sheet and copies to another
    By htiek960 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 08-04-2016, 02:49 AM
  3. Macro assigned to button in Cell A3 copies data in range B3:Z3 to another sheet...
    By tche misere in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 06-02-2014, 10:33 AM
  4. Replies: 2
    Last Post: 05-01-2013, 12:26 PM
  5. [SOLVED] Macro for copying work sheet and renaming copies after a range
    By thembahank in forum Excel Programming / VBA / Macros
    Replies: 13
    Last Post: 03-12-2013, 04:37 AM
  6. Replies: 6
    Last Post: 07-25-2012, 07:55 AM
  7. Replies: 2
    Last Post: 11-12-2009, 07:18 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