+ Reply to Thread
Results 1 to 16 of 16

Drop down list that sets up next drop down list in a form....

  1. #1
    Registered User
    Join Date
    06-27-2013
    Location
    Sainte Genevieve, MO
    MS-Off Ver
    Excel 2003
    Posts
    21

    Drop down list that sets up next drop down list in a form....

    I am working on a form for our shop guys to use when setting up a job. Essentially I have a "Type" Drop down list where they have three options. The Type range is on sheet 5.

    The next drop down list is where I am having problems. I have three sheets that have dynamic ranges with tool numbers in them. I want to be able to pick from the first drop down list and select say End Mill, after selecting End Mill, the next drop down list only displays end mills.

    I have tried some If and then statements but not coming close.

    Any help would be appreciated.

    PS: I have seen examples but most of the time those are pulling from the same sheet. If it's not possible let me know.

  2. #2
    Valued Forum Contributor Harribone's Avatar
    Join Date
    02-24-2013
    Location
    Midlands, UK
    MS-Off Ver
    Excel 2019/365
    Posts
    570

    Re: Drop down list that sets up next drop down list in a form....

    Create a list of End Mills that you want to show up. Select that range and name it 'End Mill'. Note this needs to be the same as it appears in the first drop down. Do this for each of the options.
    Then usedata validation to create you second drop down and set the drop down list to =INDIRECT(A1) where A1 is the cell location of the first drop down.
    Say thanks, click *

  3. #3
    Valued Forum Contributor
    Join Date
    05-20-2013
    Location
    Ohio, USA
    MS-Off Ver
    Excel 2013
    Posts
    941

    Re: Drop down list that sets up next drop down list in a form....

    The examples you have seen work regardless of sheet location of named ranges (assuming you've seen the same ones I have).

    One caveat you may run into is if your Type list has End Mill in it, you cannot have a space in your End Mill list's defined name. I would go with naming it EndMill, then used the following formula for your data validation...

    =INDIRECT(SUBSTITUTE(A1," ",""))

    ...where A1 would be changed to the cell address of the Type selection.

  4. #4
    Valued Forum Contributor
    Join Date
    05-20-2013
    Location
    Ohio, USA
    MS-Off Ver
    Excel 2013
    Posts
    941

    Re: Drop down list that sets up next drop down list in a form....

    Quote Originally Posted by Harribone View Post
    Create a list of End Mills that you want to show up. Select that range and name it 'End Mill'. Note this needs to be the same as it appears in the first drop down. Do this for each of the options.
    Then usedata validation to create you second drop down and set the drop down list to =INDIRECT(A1) where A1 is the cell location of the first drop down.
    Ha! We essentially said the same thing... but as a elaborated to, you can't have a space in the list name.

    (Oh.. BTW, I started my reply before you posted, but got sidetracked and didn't check if anyone had posted before I submitted mine.)

  5. #5
    Valued Forum Contributor
    Join Date
    05-20-2013
    Location
    Ohio, USA
    MS-Off Ver
    Excel 2013
    Posts
    941

    Re: Drop down list that sets up next drop down list in a form....

    Oh... another thing for Vike... when you define the named range, make sure the Scope is set for Workbook and not a specific sheet.

  6. #6
    Registered User
    Join Date
    06-27-2013
    Location
    Sainte Genevieve, MO
    MS-Off Ver
    Excel 2003
    Posts
    21

    Re: Drop down list that sets up next drop down list in a form....

    Thank you exactly what I wanted. Another quick question.........


    If End Mills show up I have it where it will populate the the categories such as flute number and length. Is there an easy way to have it change out the categories if Drill is selected such as depth instead of say tool holder.

    Would that be a vlookup? Where it looks to the original drop down list to populate the category type, and the second drop down list populate the actual data?

  7. #7
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,929

    Re: Drop down list that sets up next drop down list in a form....

    jhren, thats a really good idea to remove the " " in the name. An alternative is to use _ in the range name (End_Mill). That way, if you need to break End_Mill apart for whatever reason, you can just search for "_", rather than trying to figure out where a " " would go in EndMill
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

  8. #8
    Valued Forum Contributor
    Join Date
    05-20-2013
    Location
    Ohio, USA
    MS-Off Ver
    Excel 2013
    Posts
    941

    Re: Drop down list that sets up next drop down list in a form....

    Quote Originally Posted by FDibbins View Post
    jhren, thats a really good idea to remove the " " in the name. An alternative is to use _ in the range name (End_Mill). That way, if you need to break End_Mill apart for whatever reason, you can just search for "_", rather than trying to figure out where a " " would go in EndMill
    I considered that, but then, in the indirect formula for data validation, you'd have replace the space with an underscore, which requires a slightly more complex formula.

    Besides, we're talking about a range name. What might be the reason for needing to break it apart??? If we continue with OP's last question, the range header can still be End Mill for lookup purposes.

  9. #9
    Valued Forum Contributor
    Join Date
    05-20-2013
    Location
    Ohio, USA
    MS-Off Ver
    Excel 2013
    Posts
    941

    Re: Drop down list that sets up next drop down list in a form....

    Quote Originally Posted by Vikestand View Post
    Thank you exactly what I wanted. Another quick question.........


    If End Mills show up I have it where it will populate the the categories such as flute number and length. Is there an easy way to have it change out the categories if Drill is selected such as depth instead of say tool holder.

    Would that be a vlookup? Where it looks to the original drop down list to populate the category type, and the second drop down list populate the actual data?
    Yes, but not necessarily VLOOKUP... and yes.

  10. #10
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,929

    Re: Drop down list that sets up next drop down list in a form....

    I dont see how...
    =INDIRECT(SUBSTITUTE(A1," ","_"))
    is any more complex than...
    =INDIRECT(SUBSTITUTE(A1," ",""))
    But its really a matter of personal preferance

  11. #11
    Valued Forum Contributor
    Join Date
    05-20-2013
    Location
    Ohio, USA
    MS-Off Ver
    Excel 2013
    Posts
    941

    Re: Drop down list that sets up next drop down list in a form....

    Quote Originally Posted by FDibbins View Post
    I dont see how...
    =INDIRECT(SUBSTITUTE(A1," ","_"))
    is any more complex than...
    =INDIRECT(SUBSTITUTE(A1," ",""))
    But its really a matter of personal preferance
    You're right!!! That's my inexperience showing

  12. #12
    Registered User
    Join Date
    06-27-2013
    Location
    Sainte Genevieve, MO
    MS-Off Ver
    Excel 2003
    Posts
    21

    Re: Drop down list that sets up next drop down list in a form....

    Quote Originally Posted by jhren View Post
    Yes, but not necessarily VLOOKUP... and yes.
    Not necessarily?

    Thanks for the help so far.

  13. #13
    Registered User
    Join Date
    06-27-2013
    Location
    Sainte Genevieve, MO
    MS-Off Ver
    Excel 2003
    Posts
    21

    Re: Drop down list that sets up next drop down list in a form....

    I had a hard time in my critical writing class so try and stick with me here.

    Type: Pull down selects what type it is
    Tool: When selecting type it directs which table to pull from(Have this figured out thanks to you guys)

    Then I have the rest of these categories. This is where it gets tricky. End Mills and Drills will have a few different categories. How do I get them to populate as needed by tool type.

    Also how do get the actual table data to fill in when I am using multiple tables. I had this working when it was a simple endmill table and =vlookup.

    I would upload the sheet but the file size is too big? Picture below


    Sample.jpg
    Last edited by Vikestand; 07-08-2013 at 09:57 AM.

  14. #14
    Valued Forum Contributor
    Join Date
    05-20-2013
    Location
    Ohio, USA
    MS-Off Ver
    Excel 2013
    Posts
    941

    Re: Drop down list that sets up next drop down list in a form....

    "Not necessarily?" because we don't know how your tables are set up... may be vlookup, may be hlookup or just lookup, or perhaps an index/match formula.

    If you had it working with just an endmill table , the formula will be similar but have to account for the variable category.

    If the file size is too big to post, do a Save As, then delete stuff that is superflous and extensive to the objective (such as table data to a few examples rather than entries numbering in tens to hundreds)... i.e. reduce to simple example file. Or just create a simple example file using the same workbook structure (worksheets, table headers, ...) and only a few items in the tables. It's a lot easier to instruct on matters we don't have to speculate.

    Another option is to upload to a site which permits larger file storage (e.g. Skydrive, Google Drive) and provide a link here. I'll even PM you with one of my email addresses if you want to send that way without file size reduction.

  15. #15
    Valued Forum Contributor
    Join Date
    05-20-2013
    Location
    Ohio, USA
    MS-Off Ver
    Excel 2013
    Posts
    941

    Re: Drop down list that sets up next drop down list in a form....

    duplicate...

  16. #16
    Registered User
    Join Date
    06-27-2013
    Location
    Sainte Genevieve, MO
    MS-Off Ver
    Excel 2003
    Posts
    21

    Re: Drop down list that sets up next drop down list in a form....

    Thanks, I just sent you an email/attachment.

+ 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