+ Reply to Thread
Results 1 to 28 of 28

Help With Vehicle Fitment Cell

  1. #1
    Registered User
    Join Date
    02-05-2020
    Location
    Phoenix, AZ
    MS-Off Ver
    office 365
    Posts
    17

    Question Help With Vehicle Fitment Cell

    I have a Jeep parts online store and uploading data sheets is a real chore. I have one cell called "Fitment" and in that cell it looks like this:

    fitment
    2007,2017,Jeep,Wrangler

    Now, this is an issue because the way it imports this into woocommerce it creates 2007 as a parent on its own and no children but then once it gets passed 2007 it creates 2017 with Jeep then Wrangler as children and that is correct.
    I almost need some crazy cool formula that sees the above example and does this:

    2007,Jeep,Wrangler|2008,Jeep,Wrangler|2009,Jeep,Wrangler so on and so fourth.

    The sheets can have 1200 products and its just crazy. Here is what it really looks like in the fitment cell.

    2007,2017,Jeep,Wrangler,|2007,2016,Jeep,Wrangler,Unlimited Rubicon|2007,2016,Jeep,Wrangler,Unlimited Sahara|2007,2010,Jeep,Wrangler,Unlimited X|2010,2016,Jeep,Wrangler,Unlimited Sport|2011,2011,Jeep,Wrangler,Unlimited 70th Anniversary|2016,2016,Jeep,Wrangler,Unlimited 75th Anniversary|2016,2016,Jeep,Wrangler,Unlimited Sport S|2018,2018,Jeep,Wrangler JK,

    Can you save me anyone? Help!

  2. #2
    Forum Expert dosydos's Avatar
    Join Date
    12-09-2015
    Location
    Massachusetts
    MS-Off Ver
    365(PC) V:2308
    Posts
    1,472

    Re: Help With Vehicle Fitment Cell

    Is the below all in one cell?

    2007,2017,Jeep,Wrangler,|2007,2016,Jeep,Wrangler,Unlimited Rubicon|2007,2016,Jeep,Wrangler,Unlimited Sahara|2007,2010,Jeep,Wrangler,Unlimited X|2010,2016,Jeep,Wrangler,Unlimited Sport|2011,2011,Jeep,Wrangler,Unlimited 70th Anniversary|2016,2016,Jeep,Wrangler,Unlimited 75th Anniversary|2016,2016,Jeep,Wrangler,Unlimited Sport S|2018,2018,Jeep,Wrangler JK,
    <----- If you are happy with your solution please click on the "* Add Reputation" as a way to say thank you.

  3. #3
    Forum Expert dosydos's Avatar
    Join Date
    12-09-2015
    Location
    Massachusetts
    MS-Off Ver
    365(PC) V:2308
    Posts
    1,472

    Re: Help With Vehicle Fitment Cell

    if not please add a sample worksheet so we know exactly what you are dealing with. See yellow banner at top for instructions

  4. #4
    Registered User
    Join Date
    02-05-2020
    Location
    Phoenix, AZ
    MS-Off Ver
    office 365
    Posts
    17

    Re: Help With Vehicle Fitment Cell

    Yes its one cell.

  5. #5
    Forum Expert dosydos's Avatar
    Join Date
    12-09-2015
    Location
    Massachusetts
    MS-Off Ver
    365(PC) V:2308
    Posts
    1,472

    Re: Help With Vehicle Fitment Cell

    Lets say all that data is in cell A1.
    select A1 and then go to DATA ribbon and then TEXT TO COLUMNS
    Select Delimited and then hit Next.
    Only have "OTHER" checked and then in the space next to it type a "|" without quotations. this is the vertical line by the way the one you hit on your keyboard above the enter button with shift.
    Hit Finish

    You will now have the individual lines split into columns on row 1.
    now in cell A2 paste this array formula. (as this is an array formula you must enter it with CTRL+SHIFT+ENTER. If done so correctly { } will be put around your formula.
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    Once this is done drag this formula all the way over to the right.
    In cell A4 paste this standard formula.
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    This should give you the outcome of all years listed for each individual automobile in one cell.

    good luck

  6. #6
    Registered User
    Join Date
    02-05-2020
    Location
    Phoenix, AZ
    MS-Off Ver
    office 365
    Posts
    17

    Re: Help With Vehicle Fitment Cell

    I am attaching an example.xlsx Can you look at the fitment column and see if that will work and be efficient for what I am trying to do?
    Attached Files Attached Files

  7. #7
    Registered User
    Join Date
    02-05-2020
    Location
    Phoenix, AZ
    MS-Off Ver
    office 365
    Posts
    17

    Re: Help With Vehicle Fitment Cell

    I forgot to mention it comes out like this 1997 Jeep, Wrangler, Sahara but it needs a , after 1997 as well.

  8. #8
    Forum Expert dosydos's Avatar
    Join Date
    12-09-2015
    Location
    Massachusetts
    MS-Off Ver
    365(PC) V:2308
    Posts
    1,472

    Re: Help With Vehicle Fitment Cell

    ill hopefully have time to take a look at this on monday

  9. #9
    Registered User
    Join Date
    02-04-2020
    Location
    Mississippi
    MS-Off Ver
    2016
    Posts
    15

    Re: Help With Vehicle Fitment Cell

    That's a nice trick Dosydos. I will be able to use that for some things in the future.

    Here is the example workbook with Dosydos's solution showing each step of the conversion on another sheet.

    So thank Dosydos. I was just curious to see how his solution worked so I tried it on your workbook and figured I would upload it back being I had already did the conversion.
    Attached Files Attached Files

  10. #10
    Forum Expert
    Join Date
    07-06-2004
    Location
    Northern California
    MS-Off Ver
    2K, 2003, 2010, O365
    Posts
    1,490

    Re: Help With Vehicle Fitment Cell

    Quote Originally Posted by dosydos View Post
    . . .
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    . . .
    You and OP both show Office 365. If so, why use the volatile INDIRECT or the ROW(INDIRECT()) idiom when you could use the new nonvolatile SEQUENCE? Also picky: since INDIRECT expects a string, what's the value in the VALUE calls? Granted you'd need to call LEFT 2 times for SEQUENCE: SEQUENCE(MID(A1,6,4)-LEFT(A1,4),1,--LEFT(A1,4)).

  11. #11
    Forum Expert
    Join Date
    09-01-2012
    Location
    Norway
    MS-Off Ver
    Office 365
    Posts
    2,843

    Re: Help With Vehicle Fitment Cell

    Well this was fun! To be honest I'm not that good at (comfortable, confident etc.) working with arrays in VBA. I do however enjoy array formulas. So this spectacle of a solution uses Textjoin both horizontally and vertically on a separate sheet to solve the task but only for one cell. VBA is then used to loop through and bounce each cell off the calculation sheet and back.
    I'm sure some people here would rather swim with crocodiles than using a wacko macro like this but overall I'm still satisfied with how it turned out.
    Please Login or Register  to view this content.
    All the formulas look like this:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    Formula: copy to clipboard
    Please Login or Register  to view this content.

    Formula: copy to clipboard
    Please Login or Register  to view this content.

    Formula: copy to clipboard
    Please Login or Register  to view this content.
    (array this one)


    Formula: copy to clipboard
    Please Login or Register  to view this content.




    Edit: reuploaded, there were some bugs
    Attached Files Attached Files
    Last edited by Jacc; 02-10-2020 at 04:16 AM.
    <----- If you were helped by my posts you can say "Thank you" by clicking the star symbol down to the left

    If the problem is solved, finish of the thread by clicking SOLVED under Thread Tools
    I don't wish to leave you with no answer, yet I sometimes miss posts. If you feel I forgot you, remind me with a PM or just bump the thread.

  12. #12
    Registered User
    Join Date
    02-05-2020
    Location
    Phoenix, AZ
    MS-Off Ver
    office 365
    Posts
    17

    Re: Help With Vehicle Fitment Cell

    You guys are super smart! I will start playing with this tomorrow. I appreciate all that time you're putting into helping me!

  13. #13
    Forum Expert dosydos's Avatar
    Join Date
    12-09-2015
    Location
    Massachusetts
    MS-Off Ver
    365(PC) V:2308
    Posts
    1,472

    Re: Help With Vehicle Fitment Cell

    Derwoods post above #9, did a fantastic job at using your data and showing step by step directions on how the formulas will work. If you want a non macro-way i would follow his post.

    @hrlngrv i was unaware of the SEQUENCE function. Upon looking at the office website, it is still in beta and is only available to Office insiders, which i guess the company i work for is not. While reading over the functions makeup it does indeed look like when this function is released to the public it will offer much versatility and could definitely be applied for the solution cjs was looking for.

    https://support.office.com/en-us/art...4-2eb78519ca90

  14. #14
    Registered User
    Join Date
    02-05-2020
    Location
    Phoenix, AZ
    MS-Off Ver
    office 365
    Posts
    17

    Re: Help With Vehicle Fitment Cell

    So this importer I use wants it in this format. Would it be hard to tweak it?
    1997,Jeep,Wrangler,Sahara|1997,Jeep,Wrangler,SE|1997,Jeep,Wrangler,Sport|1998,Jeep,Wrangler,Sahara|1998,Jeep,Wrangler,SE|1998,Jeep,Wrangler,Sport|1999,Jeep,Wrangler,Sahara|1999,Jeep,Wrangler,SE|1999,Jeep,Wrangler,Sport

    Again I really appreciate the help with this. Life savers!

  15. #15
    Forum Expert
    Join Date
    09-01-2012
    Location
    Norway
    MS-Off Ver
    Office 365
    Posts
    2,843

    Re: Help With Vehicle Fitment Cell

    Something like this:

  16. #16
    Registered User
    Join Date
    02-05-2020
    Location
    Phoenix, AZ
    MS-Off Ver
    office 365
    Posts
    17

    Re: Help With Vehicle Fitment Cell

    Looks empty...

  17. #17
    Forum Expert
    Join Date
    09-01-2012
    Location
    Norway
    MS-Off Ver
    Office 365
    Posts
    2,843

    Re: Help With Vehicle Fitment Cell

    Just a second...

  18. #18
    Forum Expert
    Join Date
    09-01-2012
    Location
    Norway
    MS-Off Ver
    Office 365
    Posts
    2,843

    Re: Help With Vehicle Fitment Cell

    Ok this will be more than a second but I'll look into it now. One of these days I need to learn to read the full text of a post instead of just every 25 word....

  19. #19
    Registered User
    Join Date
    02-05-2020
    Location
    Phoenix, AZ
    MS-Off Ver
    office 365
    Posts
    17

    Re: Help With Vehicle Fitment Cell

    I am as guilty of that as you are Take your time!

  20. #20
    Forum Expert
    Join Date
    09-01-2012
    Location
    Norway
    MS-Off Ver
    Office 365
    Posts
    2,843

    Re: Help With Vehicle Fitment Cell

    Ok so I tweaked it to do something that hopefully resembles a solution.
    Same VBA loop, just a bit different array formula.
    Attached Files Attached Files
    Last edited by Jacc; 02-10-2020 at 06:14 PM.

  21. #21
    Forum Expert
    Join Date
    07-06-2004
    Location
    Northern California
    MS-Off Ver
    2K, 2003, 2010, O365
    Posts
    1,490

    Re: Help With Vehicle Fitment Cell

    Quote Originally Posted by dosydos View Post
    . . . the SEQUENCE function . . . is still in beta and is only available to Office insiders, . . .
    FWIW, it's also available in Excel Online. The note on availability is from September 2018. It sure seems to take MSFT's Excel developers team considerable time to implement anything new. Frustrating when the features new to Excel have been available for use in Google Sheets for years. NIH Syndrome is a very hard psychological malady to cure. [FWIW, it only took MSFT 8 years from Quattro Pro for Windows introducing colored worksheet tabs in the early 1990s for Excel 2002 to get them in the early 2000s. With global warming, glaciers move faster than the Excel developers team.]

  22. #22
    Registered User
    Join Date
    02-05-2020
    Location
    Phoenix, AZ
    MS-Off Ver
    office 365
    Posts
    17

    Re: Help With Vehicle Fitment Cell

    Jacc - That works perfectly! You rock! So I have many of these data sheets, do I just copy the calc sheet to each new sheet to make this work?

  23. #23
    Forum Expert
    Join Date
    09-01-2012
    Location
    Norway
    MS-Off Ver
    Office 365
    Posts
    2,843

    Re: Help With Vehicle Fitment Cell

    Thansk! Well as of now, no. However it is a good idea, I'll try to applicatifize it a bit and implement that. I'm going into a busy period so it may take a day or two.
    If you have to do things now you are better of copying a sheet of data into this workbook and rename it "data". You can run the macro from Alt + F8

  24. #24
    Registered User
    Join Date
    02-05-2020
    Location
    Phoenix, AZ
    MS-Off Ver
    office 365
    Posts
    17

    Thumbs up Re: Help With Vehicle Fitment Cell

    Understood, I cant say thank you enough, this is really going to help me!

  25. #25
    Forum Expert
    Join Date
    09-01-2012
    Location
    Norway
    MS-Off Ver
    Office 365
    Posts
    2,843

    Re: Help With Vehicle Fitment Cell

    This should do the trick:
    Attached Files Attached Files
    Last edited by Jacc; 02-13-2020 at 09:26 AM.

  26. #26
    Registered User
    Join Date
    02-05-2020
    Location
    Phoenix, AZ
    MS-Off Ver
    office 365
    Posts
    17

    Re: Help With Vehicle Fitment Cell

    Says the file is corrupt when I try to download it. What would be the easiest way in this scenario to remove the extra year and comma?

    Example:
    2011,2011,Jeep,Wrangler,70th,Anniversary|2016,2016,Jeep,Wrangler,75th,Anniversary

    What it should look like:
    2011,Jeep,Wrangler,70th,Anniversary|2016,Jeep,Wrangler,75th,Anniversary

  27. #27
    Forum Expert
    Join Date
    09-01-2012
    Location
    Norway
    MS-Off Ver
    Office 365
    Posts
    2,843

    Re: Help With Vehicle Fitment Cell

    Yeah I was afraid of that. It works on my PC a couple of times and then corrupts. I downloaded the file I posted, ran the macro successfully 3 times then crash. It seems it didn't like when I put the code in the sheet module as you requested. In general I feel like it's still 2016 and this guy nailed it: https://www.reddit.com/r/Windows10/c...on_windows_10/

    Edit: I just reverted back to modules and it keeps crashing...

  28. #28
    Forum Expert
    Join Date
    09-01-2012
    Location
    Norway
    MS-Off Ver
    Office 365
    Posts
    2,843

    Re: Help With Vehicle Fitment Cell

    Quote Originally Posted by cjs1031 View Post
    What would be the easiest way in this scenario to remove the extra year and comma?

    Example:
    2011,2011,Jeep,Wrangler,70th,Anniversary|2016,2016,Jeep,Wrangler,75th,Anniversary

    What it should look like:
    2011,Jeep,Wrangler,70th,Anniversary|2016,Jeep,Wrangler,75th,Anniversary
    Not sure what you mean here. Doesn't it work as intended in post 20?
    Last edited by Jacc; 02-18-2020 at 04:51 AM.

+ 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. Vehicle Time Table in Excel to Vehicle Movement Graph in Excel
    By Petrus in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 07-24-2019, 04:54 AM
  2. Index vehicle, driver and vehicle wise revenue report.
    By dackson in forum Excel Formulas & Functions
    Replies: 41
    Last Post: 06-02-2017, 01:40 AM
  3. VBA: I want it to go down column D and write "Vehicle" in the cell after the last cell.
    By mattress58 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 09-03-2013, 02:16 PM
  4. Replies: 2
    Last Post: 01-30-2013, 12:06 PM
  5. Vehicle Age
    By kingcal in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 01-14-2008, 06:17 PM
  6. Vehicle Age
    By Badvgood in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 12-25-2007, 01:20 AM
  7. Vehicle Age
    By chris2403 in forum Excel Formulas & Functions
    Replies: 13
    Last Post: 10-16-2007, 11:19 AM

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