+ Reply to Thread
Results 1 to 5 of 5

Indirect/Substitute combobox to populate graph

  1. #1
    Registered User
    Join Date
    06-03-2009
    Location
    N.Ireland
    MS-Off Ver
    Excel 2003
    Posts
    76

    Indirect/Substitute combobox to populate graph

    I have created a worksheet that uses two comboboxes to generate a chart based on the values that have been selected and this is working well. However i would like to use the INDIRECT/SUBSTITUTE function to display specific values based on the selection of a combobox. I have used the INDIRECT function before using the validation list option but i want to use it with a combobox, can anyone help me/provide me with some advice on how to do this?

    My workbook at present:
    Attached Files Attached Files
    Last edited by PRodgers; 09-02-2009 at 04:31 AM.

  2. #2
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: Indirect/Substitute combobox to populate graph

    Can you elaborate with an example of what you mean?
    Where there is a will there are many ways.

    If you are happy with the results, please add to the contributor's reputation by clicking the reputation icon (star icon) below left corner

    Please also mark the thread as Solved once it is solved. Check the FAQ's to see how.

  3. #3
    Registered User
    Join Date
    06-03-2009
    Location
    N.Ireland
    MS-Off Ver
    Excel 2003
    Posts
    76

    Re: Indirect/Substitute combobox to populate graph

    Quote Originally Posted by NBVC View Post
    Can you elaborate with an example of what you mean?
    NBVC i basically want two comboboxes one "Hospital" and the other "Ward", i want when i user selects a hospital only the wards in this hospital are available. The above workbook that I posted is the same kind of idea of what i want but i want to use the INDIRECT/SUBSTITUTE function to restrict what is being displayed in the comboboxs, im unsure how to use this function within a combobox. Any help/advice is much appreciated.

  4. #4
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: Indirect/Substitute combobox to populate graph

    Create a named range for the dynamic range.

    So If, for example on your attached example you have the Vehicle combobox and say you have different combinations of fuel types based on vehicle chosen.. so now you would have separate named ranges for Motorcyle, Car, Bus, etc. listing the fuel types....

    Then you can use the B2 result (which displays the choice of vehicle you made in a cell)... and name a range, eg. DynamicRange and use formula =Indirect($B$2)

    Now, the Fuel combobox, input range would be DynamicRange

    I did a quick sample on the attached...
    Attached Files Attached Files

  5. #5
    Registered User
    Join Date
    06-03-2009
    Location
    N.Ireland
    MS-Off Ver
    Excel 2003
    Posts
    76

    Re: Indirect/Substitute combobox to populate graph

    Quote Originally Posted by NBVC View Post
    Create a named range for the dynamic range.

    So If, for example on your attached example you have the Vehicle combobox and say you have different combinations of fuel types based on vehicle chosen.. so now you would have separate named ranges for Motorcyle, Car, Bus, etc. listing the fuel types....

    Then you can use the B2 result (which displays the choice of vehicle you made in a cell)... and name a range, eg. DynamicRange and use formula =Indirect($B$2)

    Now, the Fuel combobox, input range would be DynamicRange

    I did a quick sample on the attached...
    NBVC thanks for you help, thats works exactly the way i want it.
    Last edited by NBVC; 09-02-2009 at 07:39 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