+ Reply to Thread
Results 1 to 7 of 7

Please help: Need to Split two columns with multiple text values into distinct rows

  1. #1
    Registered User
    Join Date
    03-09-2021
    Location
    South Jersey
    MS-Off Ver
    365/2016
    Posts
    3

    Exclamation Please help: Need to Split two columns with multiple text values into distinct rows

    So I was hoping someone could assist me. I have been trying varying ways of doing this, but I cannot find a way that will make this automated/less manual. I inherited a process that is extremely manual and will take me hours to do manually. However, I believe this can be solved with VB, but I have no idea where to begin with this. Unfortunately, I lack the skills of the VB gods and I cannot even figure out where to start with this. Could someone please offer some guidance or maybe a similar setup they had and how it was solved?

    One thing to notate, if it helps at all. When the column labeled Day/Night contains multiple values, they will match the # of days of the week (frequency basically) when the day/night is mixed. To give you an example, when the shift schedule says Day, Night, Day for the Day/Night column, it will be in order for the days of the week. So what I mean by that is, if Days of the week reads Mon, Wed, Fri; Mon would be Day, Wed is Night and Fri would be Day shift.


    Data example is attached.
    Attached Files Attached Files

  2. #2
    Spammer
    Join Date
    10-23-2012
    Location
    Adelaide, Australia
    MS-Off Ver
    Excel 2003, Office 365
    Posts
    1,237

    Re: Please help: Need to Split two columns with multiple text values into distinct rows

    Try this;
    Please Login or Register  to view this content.
    Last edited by Croweater; 03-10-2021 at 12:41 AM.

  3. #3
    Registered User
    Join Date
    03-09-2021
    Location
    South Jersey
    MS-Off Ver
    365/2016
    Posts
    3

    Re: Please help: Need to Split two columns with multiple text values into distinct rows

    I'm going to give this a try today or tomorrow and report back. Thanks for the suggestion, I will follow up soon.

  4. #4
    Registered User
    Join Date
    03-09-2021
    Location
    South Jersey
    MS-Off Ver
    365/2016
    Posts
    3

    Re: Please help: Need to Split two columns with multiple text values into distinct rows

    Hey Croweater, Thanks for the help on this. This does appear to work. I just now have to figure out how to map it over to my real world example. I had changed some things to keep the example file from sharing too much information.

    I have altered the code to fit to what I am doing on my spreadsheet. I have 5 tabs that need the exact same actions performed. How would I need to edit the below code to make this work on all 5 tabs at once?




    Please Login or Register  to view this content.
    Last edited by alansidman; 11-06-2021 at 12:03 AM.

  5. #5
    Spammer
    Join Date
    10-23-2012
    Location
    Adelaide, Australia
    MS-Off Ver
    Excel 2003, Office 365
    Posts
    1,237

    Re: Please help: Need to Split two columns with multiple text values into distinct rows

    Something like this in a class module rather than executed from a sheet. (Might need to right click and insert a module)

    You may also want to turn screen updating off etc.

    Please Login or Register  to view this content.
    Last edited by Croweater; 11-05-2021 at 09:46 PM.

  6. #6
    Forum Moderator alansidman's Avatar
    Join Date
    02-02-2010
    Location
    Steamboat Springs, CO
    MS-Off Ver
    MS Office 365 Version 2403 Win 11 Home 64 Bit
    Posts
    23,810

    Re: Please help: Need to Split two columns with multiple text values into distinct rows

    @Honorary Title

    Code Tags Added
    Your post does not comply with Rule 2 of our Forum RULES. Use code tags around code.

    Posting code between [CODE]Please [url=https://www.excelforum.com/login.php]Login or Register [/url] to view this content.[/CODE] tags makes your code much easier to read and copy for testing, it also maintains VBA formatting.

    Highlight your code and click the # icon at the top of your post window. More information about these and other tags can be found at http://www.excelforum.com/forum-rule...rum-rules.html



    (I have added them for you today. Please take a few minutes to read all Forum Rules and comply in the future.)
    Alan עַם יִשְׂרָאֵל חַי


    Change an Ugly Report with Power Query
    Database Normalization
    Complete Guide to Power Query
    Man's Mind Stretched to New Dimensions Never Returns to Its Original Form

  7. #7
    Forum Expert sintek's Avatar
    Join Date
    12-04-2015
    Location
    Cape Town
    MS-Off Ver
    2013 | 2016 | 2019
    Posts
    13,122

    Re: Please help: Need to Split two columns with multiple text values into distinct rows

    Another Option...
    Please Login or Register  to view this content.
    Attached Files Attached Files
    Good Luck
    I don't presume to know what I am doing, however, just like you, I too started somewhere...
    One-day, One-problem at a time!!!
    If you feel I have helped, please click on the star to left of post [Add Reputation]
    Also....add a comment if you like!!!!
    And remember...Mark Thread as Solved.
    Excel Forum Rocks!!!

+ 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] Edit vba to split values over 10 columns and required rows
    By JNEWMAN in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 04-01-2019, 11:16 AM
  2. Replies: 1
    Last Post: 01-15-2016, 09:59 AM
  3. Split multiple Delimiter field with Header into Multiple Columns and Rows
    By omershafiq2012 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 03-27-2015, 08:01 AM
  4. [SOLVED] Finding distinct values across multiple columns - FREQUENCY array?
    By brokenbiscuits in forum Excel General
    Replies: 4
    Last Post: 01-12-2015, 09:06 AM
  5. split multiple semicolon separated values into new rows for multiple columns
    By bruno08102013 in forum Excel Programming / VBA / Macros
    Replies: 21
    Last Post: 01-05-2014, 05:27 PM
  6. Replies: 0
    Last Post: 08-03-2012, 04:31 PM
  7. Replies: 1
    Last Post: 03-02-2011, 04:14 PM

Tags for this Thread

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