Closed Thread
Results 1 to 5 of 5

Drop Down list within a drop down list.

  1. #1
    Registered User
    Join Date
    12-25-2007
    Posts
    5

    Drop Down list within a drop down list.

    I'm creating a workbook for an exercise program for my clients that contains a printable template in one worksheet and a database of exercises in another worksheet. I have no problem creating a typical drop down list, however I have been unable to figure out how to (or if it is even possible) create a drop down list within a drop down list.

    Let's say I've sorted my exercise database into 2 types of exercise: upper and lower body and I have 2 exercises for each type of exercise: Upper body: pushups and pullups, and lower body: squats and lunges.

    Is it possible, in a single cell to first select upper or lower body and then once that is selected, the list changes to those exercises under my first selection.

    ex. In A1, my goal is to select Squats. Is there a way to first select lower body from a drop down list and then the list changes so I can select squats in the same cell, A1?

    Or is there a better way to do this?

    Thanks.

  2. #2
    Forum Contributor VBA Noob's Avatar
    Join Date
    04-25-2006
    Location
    London, England
    MS-Off Ver
    xl03 & xl 07(Jan 09)
    Posts
    11,988
    See if this event macro would help

    To see code right click sheet tab > select view code

    Merry Christmas

    VBA Noob
    Attached Files Attached Files
    _________________________________________


    Credo Elvem ipsum etian vivere
    _________________________________________
    A message for cross posters

    Please remember to wrap code.

    Forum Rules

    Please add to your signature if you found this link helpful. Excel links !!!

  3. #3
    Registered User
    Join Date
    12-25-2007
    Posts
    5
    This is great! Just what I was looking for. I have no VB knowledge but can decipher the code enough to be able to put in literally thousands of exercises.

    I have two additional questions, and unfortunately have the feeling the code is about to get much more complicated:

    1) once i have selected the exercise (ex. upper body>pushup), when I click again is there a way to keep the upper body exercises listed i.e. pushup, pullup in the box, and perhaps have a keyboard shortcut to make the cell go back to the first drop down list (which contains upper body, lower body)? The reason for this is that I have multiple progressions for exercise ex. pushup: from the knee progresses to regular pushups, and I would like to easily progress my clients, clicking the dropdown list and moving down one exercise rather than going through the entire menu again.

    2) Since I will obviously be putting more than one exercise on a page, can the code be manipulated so that the code applies to multiple cells (but obviously be able to select different exercises in each cell) in efforts to keep the code shorter?

    Thanks a bunch for the help so quickly.

    Merry Christmas.

  4. #4
    Registered User
    Join Date
    11-01-2011
    Location
    Wagga Wagga, Australia
    MS-Off Ver
    Excel 2007
    Posts
    1

    Re: Drop Down list within a drop down list.

    This sounds EXACTLY like the problem I am now having, but the zip file won't open in my Excel 2007. Is there anything you can do for me?

  5. #5
    Forum Expert
    Join Date
    12-23-2006
    Location
    germany
    MS-Off Ver
    XL2003 / 2007 / 2010
    Posts
    6,326

    Re: Drop Down list within a drop down list.

    Your post does not comply with Rule 2 of our Forum RULES. Don't post a question in the thread of another member -- start your own thread. If you feel it's particularly relevant, provide a link to the other thread.

Closed 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