+ Reply to Thread
Results 1 to 13 of 13

Move Group of Rows from a Specific Column (Based on Matching Criteria) to a new Sheet

  1. #1
    Registered User
    Join Date
    02-17-2013
    Location
    FL
    MS-Off Ver
    Excel 2003
    Posts
    81

    Move Group of Rows from a Specific Column (Based on Matching Criteria) to a new Sheet

    Hello, I attached a sample workbook to try and further explain my question.

    So, in the "Info" sheet I want to move all of the cells based on the criteria of Column B.

    So, I want to copy Row 2 to the "One" Sheet because it has the word "One" in Column B.

    Basically I want to be able to change the data in the "Info" sheet and it move to the other sheet's based on that Column B criteria.

    There are 4 more sheets, but really as long as I figure out how to do this one example, I can apply it to the rest in the sample workbook.

    Thanks again for any help!
    Attached Files Attached Files

  2. #2
    Valued Forum Contributor
    Join Date
    02-09-2012
    Location
    Mauritius
    MS-Off Ver
    Excel 2007
    Posts
    1,055

    Re: Move Group of Rows from a Specific Column (Based on Matching Criteria) to a new Sheet

    Hi.

    Try this out:

    Workbook2.xlsm

    This is the macro code:

    Please Login or Register  to view this content.
    Click *, if my suggestion helps you. Have a good day!!

  3. #3
    Registered User
    Join Date
    02-17-2013
    Location
    FL
    MS-Off Ver
    Excel 2003
    Posts
    81

    Re: Move Group of Rows from a Specific Column (Based on Matching Criteria) to a new Sheet

    Thanks, that is very helpful. I am new to this, but I have another workbook that has the exact same cells but different words in the "One, Two, Three, Four, Five" cell spots. I guess I am wondering if I can just paste that macro code to my other workbook somehow? The other workbook is the exact same row/column alignments and just different words as mentioned above.

    Thanks again!

  4. #4
    Valued Forum Contributor
    Join Date
    02-09-2012
    Location
    Mauritius
    MS-Off Ver
    Excel 2007
    Posts
    1,055

    Re: Move Group of Rows from a Specific Column (Based on Matching Criteria) to a new Sheet

    Yes ofcourse you can use this code.

    Happy to help you .

    Good day..

  5. #5
    Registered User
    Join Date
    02-17-2013
    Location
    FL
    MS-Off Ver
    Excel 2003
    Posts
    81

    Re: Move Group of Rows from a Specific Column (Based on Matching Criteria) to a new Sheet

    I guess a better way of saying it is that I want to be able to update the data in the "Info" sheet and have it keep moving the data to each appropriate sheet. Is this possible with the above code?
    Last edited by jordan1214; 02-21-2013 at 02:37 AM.

  6. #6
    Registered User
    Join Date
    02-17-2013
    Location
    FL
    MS-Off Ver
    Excel 2003
    Posts
    81

    Re: Move Group of Rows from a Specific Column (Based on Matching Criteria) to a new Sheet

    And if so, is it as simple as copy and pasting that code into my other workbook? How did I do that? Thanks

  7. #7
    Valued Forum Contributor
    Join Date
    02-09-2012
    Location
    Mauritius
    MS-Off Ver
    Excel 2007
    Posts
    1,055

    Re: Move Group of Rows from a Specific Column (Based on Matching Criteria) to a new Sheet

    Sorry was a bit busy. Will get back to you with the updated code. Sorry again.

  8. #8
    Valued Forum Contributor
    Join Date
    02-09-2012
    Location
    Mauritius
    MS-Off Ver
    Excel 2007
    Posts
    1,055

    Re: Move Group of Rows from a Specific Column (Based on Matching Criteria) to a new Sheet

    The names in col A will be unique to each sheet or can that change?

  9. #9
    Registered User
    Join Date
    02-17-2013
    Location
    FL
    MS-Off Ver
    Excel 2003
    Posts
    81

    Re: Move Group of Rows from a Specific Column (Based on Matching Criteria) to a new Sheet

    The names in Column A will be added on to/changed if that is going to be ok.

    I may have misunderstood that. If so, then ideally the same name would be able to go to multiple sheets (Still only moving sheets based on the Column B)

    I'm just really new to this so when you sent me that last one I tried to add in a few more lines to see if it would move them to the correct sheet and it didn't, so I know my expectations are either wrong or I am doing something wrong.
    Last edited by jordan1214; 02-21-2013 at 03:08 AM.

  10. #10
    Valued Forum Contributor
    Join Date
    02-09-2012
    Location
    Mauritius
    MS-Off Ver
    Excel 2007
    Posts
    1,055

    Re: Move Group of Rows from a Specific Column (Based on Matching Criteria) to a new Sheet

    Just try this now and check if you get the desired output:

    Workbook2.xlsm

  11. #11
    Registered User
    Join Date
    02-17-2013
    Location
    FL
    MS-Off Ver
    Excel 2003
    Posts
    81

    Re: Move Group of Rows from a Specific Column (Based on Matching Criteria) to a new Sheet

    I tried to move some new data over and it didn't quite work. I think this is my fault, I thought I just needed a code and I could move it over to my workbook.

    So now I have attached the workbook I actually need this done on.

    I need to move the rows of the "Info" sheet based on Column B. (Everything is exactly the same except different numbers).

    So for example, instead of "One, Two, Three, Four, Five" the data is now "Point Guard, Shooting Guard, Small Forward, Power Forward, Center"

    So ideally I want to be able to post new data to the "Info" sheet every few days, and have it move it to one of those 5 sheets based on Column B. Is that realistic?

    I can't thank you enough, I will keep giving reputation to all your posts.
    Attached Files Attached Files
    Last edited by jordan1214; 02-21-2013 at 03:50 AM.

  12. #12
    Valued Forum Contributor
    Join Date
    02-09-2012
    Location
    Mauritius
    MS-Off Ver
    Excel 2007
    Posts
    1,055

    Re: Move Group of Rows from a Specific Column (Based on Matching Criteria) to a new Sheet

    Check this macro code:

    Sample1.xlsm

  13. #13
    Registered User
    Join Date
    02-17-2013
    Location
    FL
    MS-Off Ver
    Excel 2003
    Posts
    81

    Re: Move Group of Rows from a Specific Column (Based on Matching Criteria) to a new Sheet

    Quote Originally Posted by jraj1106 View Post
    Check this macro code:

    Attachment 215637
    That code is exactly what I was looking for. However, I am new to using Macros, so when I want to add new data to the "Info" sheet, what do I have to do to have it manually moved to each appropriate sheet (PG,SG,SF,PF,C?)

    I am able to add one line at a time and hit enter on P and it works most of the time, however, this is what I am trying to do:

    Copy and paste (or import) a group of cells to the "Info" sheet. When I try and do this to more than 1 cell, it doesn't disperse them to the other 5 sheets (PG,SG,SF,PF,C)

    Thanks again for looking at all this!
    Last edited by jordan1214; 02-28-2013 at 02:15 AM.

+ 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