+ Reply to Thread
Results 1 to 3 of 3

Copy a range of data and paste to multiple sheets using "User" as key identifier

  1. #1
    Registered User
    Join Date
    05-29-2015
    Location
    Milton Keynes, England
    MS-Off Ver
    2010
    Posts
    2

    Copy a range of data and paste to multiple sheets using "User" as key identifier

    Hi Guys,
    I am a macro novice and I am having trouble finding a way to sort a large data set by User and then select all of the data for that user and paste into their own sheet.
    I have 6 different users to differentiate from:WDC_RFGUN_1, WDC_RFGUN_2, WDC_RFGUN_3, WDC_RFGUN_4, WDC_RFGUN_5, WDC_RFGUN_6.
    I have 6 sheets named: RF1, RF2, RF3, RF4, RF5, RF6.
    I run a report every day that gives me transaction data for the said users and I paste this data set into sheet RF1. The full data set is never longer than 5000 lines, but the number of lines per user each day can vary as this shows actual work done by an individual.
    I sort the data by User and then I cut and paste each users data set from sheet RF1 into their respective sheet, where I have a number of macros that calculate work rates.

    Does anyone know the code that would automatically cut and paste the user data into the correct sheets?
    I tried recording a Macro and I manually cut and paste the data. When I re-ran the macro it worked perfectly for the current data set, but when I ran it the day after with a brand new data set it cut and pasted the exact number of cells rather than user specific data.

    Below is a small sample of my data set...please note that I said the data set can be a maximum of 5000 rows. There are 8 columns in total which never changes.
    Just to confirm; I want to cut and paste all of the data for a specific user (all the column data), not just the user name.

    SCREEN SHOT ON LINK BELOW
    Data Set.png

    If anyone could help this novice it would be most appreciated.
    Last edited by cmicmac; 05-29-2015 at 07:11 AM.

  2. #2
    Forum Expert skywriter's Avatar
    Join Date
    06-09-2014
    Location
    USA
    MS-Off Ver
    2016
    Posts
    2,760

    Re: Copy a range of data and paste to multiple sheets using "User" as key identifier

    Does anyone know the code that would automatically cut and paste the user data into the correct sheets?
    The code would have to written based on your sheet names, where the data is etc. Pictures aren't much help because there is no data that can be copied from a picture into a spreadsheet for testing.

    You should post your spreadsheet so that the coding can be done on the actual sheet. A copy of the sheet is okay. You don't need thousands of rows of data, but you do need some. You can use dummy numbers, names etc for any sensitive data. You've already shown some data in your picture so obviously that data isn't sensitive.

    ViewPic.
    Click the * Add Reputation button in the lower left hand corner of this post to say thanks.

    Don't forget to mark this thread SOLVED by going to the "Thread Tools" drop down list above your first post and choosing solved.

  3. #3
    Registered User
    Join Date
    05-29-2015
    Location
    Milton Keynes, England
    MS-Off Ver
    2010
    Posts
    2

    Re: Copy a range of data and paste to multiple sheets using "User" as key identifier

    Hi Skywriter,

    Thanks for the response......as you can probably tell I am new. Example file attached.

    27_05_15RFKPI.xlsx

    Cheers

+ 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: 18
    Last Post: 09-02-2014, 08:08 AM
  2. [SOLVED] Copy multiple rows that contain a certain "name" in column "A" then paste it into new work
    By rschlot2 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 06-18-2013, 02:25 PM
  3. Replies: 2
    Last Post: 06-06-2013, 12:45 PM
  4. Enter Data on "Main" or "Input" Sheet and Copy to One of Many Other Sheets
    By timothy_no7 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 05-21-2012, 07:29 PM
  5. Replies: 2
    Last Post: 02-28-2006, 11:25 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