+ Reply to Thread
Results 1 to 5 of 5

Copying specific cell based on two parameters and then sorting based on one parameter

  1. #1
    Registered User
    Join Date
    05-15-2012
    Location
    Guam
    MS-Off Ver
    2010
    Posts
    30

    Copying specific cell based on two parameters and then sorting based on one parameter

    Hi,

    I've been sifting through all the posts but could not find a macro that does the following exactly:
    The macro will identify whatever ID is inputted in any cell, then copy all of its respective data from the data sample, then sort it according to date.
    There should only be one date per column and one ID per row. The result will match its respective ID and placed in its appropriate cell. The ID may be a combination of letters and numbers. Also, this is a small sample size and if someone can figure out how to implement it using the max allotted rows for excel 2010.*

    data sample:
    ID 1/1/2012 1/3/2012 1/2/2012
    AAA 14 12 11
    AAA1 25 23 21
    AAB 30 32 34
    BBB 40 46 42
    BBB2 57 50 58
    CCC 69 62 64
    CCB 70 73 77
    CCC2 84 85 83

    output:

    1/1/2012 1/2/2012 1/3/2012
    BBB results
    BBB2 results

    AAA results
    CCC results

    AAA1 results
    CCC2 results

    AAB results
    CCB results

  2. #2
    Forum Expert nilem's Avatar
    Join Date
    10-22-2011
    Location
    Ufa, Russia
    MS-Off Ver
    2013
    Posts
    3,377

    Re: Copying specific cell based on two parameters and then sorting based on one parameter

    Buntalan80, can you show an example in the file - as it is and as it should?

  3. #3
    Registered User
    Join Date
    05-15-2012
    Location
    Guam
    MS-Off Ver
    2010
    Posts
    30

    Re: Copying specific cell based on two parameters and then sorting based on one parameter

    Hi nilem,

    I've attached a sample file. I'm basically just categorizing the information from the previous thread you solved earlier. See "sheet 2" in the excel file attached. Basically, I want the macro to batch copy. It would be too tedious to identify each ID (numbering in the hundreds or even thousands) individually and then sort each making sure each data point is placed in the proper date column.
    Thank you. I forgot to mention, there could be an unlimited number of categories, data points, and ID's or whatever the limit for excel 2010 is.
    Attached Files Attached Files
    Last edited by buntalan80; 05-17-2012 at 01:54 AM.

  4. #4
    Forum Expert nilem's Avatar
    Join Date
    10-22-2011
    Location
    Ufa, Russia
    MS-Off Ver
    2013
    Posts
    3,377

    Re: Copying specific cell based on two parameters and then sorting based on one parameter

    Dates can be sorted using the Custom Sort - Options - By columns.
    Group1, group2, etc. - How does the identifiers are divided into groups?

  5. #5
    Registered User
    Join Date
    05-15-2012
    Location
    Guam
    MS-Off Ver
    2010
    Posts
    30

    Re: Copying specific cell based on two parameters and then sorting based on one parameter

    Ok. So sorting won't be an issue. In regards to the grouping, I would create a custom list and just paste it in column 1 for example. Then the macro would read the list, go to the data sample and just copy the data based on the customized list.

    Thank you.

+ 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