three level dependent combobox

AnandKaushal

New Member
Joined
Oct 20, 2017
Messages
4
Hi,

I want 3 combobox in my sheet which are depended upon previous combobox data and final cell display price depended upon combination

Data Structure:-

Breverage
TEA
COFFEE

TEA
GREEN TEA
BLACK TEA

COFFEE
BLACK COFFEE
REGULAR COFFEE

POTION
SMALL
MEDIUM
LARGE

PRICE
TEA -> GREEN TEA -> SMALL -> 10
TEA -> GREEN TEA -> MEDIUM -> 20 and so on depending on combination.

Please help me solve this.
 

Excel Facts

Move date out one month or year
Use =EDATE(A2,1) for one month later. Use EDATE(A2,12) for one year later.
Anand,

My experience with first time posters on this site is that they are looking for someone to do their project for them or they think their request should be very simple. When faced with a response that is more advanced and causes them to spend more than a few minutes to solve, they give up. I usually pass on first time posters because of that.

I have done this before successfully. The final product can be scaled automatically to include many more items in each list without having to change formulas or named ranges. It is advanced. It will require many steps. You will learn something.

If you accept this mission, instructions will follow that you will need to read in detail.

Jeff
 
Upvote 0
Am I to assume that you want to take the time?

Is that your real data set? Coffees and Teas, Size, and so forth? No big deal, seams generic. I will start working on it. How large will you lists be? Tens of numbers, hundreds; just a ballpark.
 
Upvote 0
This is the Pulldown cells and the formula for getting the price. Cell D3 is the dependent dropdown cell that changes based on your selection in B3. B3 is the main choice, Tea or Coffee. Portion allows you to choose the size from a single list and isn't dependent. Price is the formula

More to come.

Excel 2013
BCDEFGH
2BeverageType Of BeveragePortionPrice
3CoffeeDecaf CoffeeMedium$4.25

<colgroup><col style="width: 25pxpx"><col><col><col><col><col><col><col></colgroup><thead>
</thead><tbody>
</tbody>
Pulldown

Worksheet Formulas
CellFormula
H3=IFERROR(VLOOKUP(BevSelected&","&D3&","&F3,FullPrice_list,2,FALSE),0)

<thead>
</thead><tbody>
</tbody>

<tbody>
</tbody>

Workbook Defined Names
NameRefers To
BevSelected=Pulldown!$B$3
FullPrice_list=OFFSET(Setup!$J$1,1,0,MATCH("zzzzzzzzzz",Setup!$J:$J)-ROW(Setup!$J$1),2)

<thead>
</thead><tbody>
</tbody>

<tbody>
</tbody>
 
Upvote 0
This is the Setup sheet. These are the maintained lists. All of the lists or tables have dynamic named ranges supporting the dropdowns.

Each of the names for the named ranges are at the top. As you add or remove items so does the list change in size. Columns B, D, E, H, and K are manually maintained by you. Column F is a series of formulas to aggregate the list based on the choice from the PullDown sheet. You only need to copy the formula into F2 and then copy that down. You may need to add more aggregate formulas as your list grows. Column J needs to be specifically formatted; the price formula is counting on no spaces after the commas that concatenate the beverages and portions. Column E defines which type of beverage it is from the Beverage_list.

Here are the named ranges. Copy the date below before creating the named ranges:
Agg_list
=OFFSET(Setup!$F$1,1,0,MATCH("zzzzzzzzzz",Setup!$F:$F)-ROW(Setup!$F$1),1)
Beverage_list =OFFSET(Setup!$B$1,1,0,MATCH("zzzzzzzzzz",Setup!$B:$B)-ROW(Setup!$B$1),1)
BevSelected =Pulldown!$B$3
BevType_list =OFFSET(Setup!$D$1,1,0,MATCH("zzzzzzzzzz",Setup!$D:$D)-ROW(Setup!$D$1),1)
Full_List =OFFSET(Setup!$J$1,1,0,MATCH("zzzzzzzzzz",Setup!$J:$J)-ROW(Setup!$J$1),1)
FullPrice_list
=OFFSET(Setup!$J$1,1,0,MATCH("zzzzzzzzzz",Setup!$J:$J)-ROW(Setup!$J$1),2)
Portion_list =OFFSET(Setup!$H$1,1,0,MATCH("zzzzzzzzzz",Setup!$H:$H)-ROW(Setup!$H$1),1)
Type_list =OFFSET(Setup!$D$1,1,1,MATCH("zzzzzzzzzz",Setup!$E:$E)-ROW(Setup!$D$1),1)

Excel 2013
BCDEFGHIJK
1Beverage_listBevType_listType_listAgg_listPortionFull ListPrice
2TeaGreen TeaTeaBlack CoffeeSmallTea,Green Tea,Small$2.50
3CoffeeBlack TeaTeaRegular CoffeeMediumTea,Green Tea,Medium$3.00
4Black Decaf TeaTeaEspressoLargeTea,Green Tea,Large$3.50
5Herbal TeaTeaDecaf CoffeeTea,Black Tea,Small$2.50
6Black CoffeeCoffee0Tea,Black Tea,Medium$3.00
7Regular CoffeeCoffee0Tea,Black Tea,Large$3.50
8EspressoCoffee0Tea,Black Decaf Tea,Small$2.75
9Decaf CoffeeCoffee0Tea,Black Decaf Tea,Medium$3.25
100Tea,Black Decaf Tea,Large$3.75
110Tea,Herbal Tea,Small$2.50
120Tea,Herbal Tea,Medium$3.00
130Tea,Herbal Tea,Large$3.50
140Coffee,Black Coffee,Small$3.75
150Coffee,Black Coffee,Medium$4.25
160Coffee,Black Coffee,Large$4.75
170Coffee,Regular Coffee,Small$3.75
180Coffee,Regular Coffee,Medium$4.25
190Coffee,Regular Coffee,Large$4.75
200Coffee,Espresso,Small$4.00
210Coffee,Espresso,Medium$4.50
220Coffee,Espresso,Large$5.00
230Coffee,Decaf Coffee,Small$3.75
240Coffee,Decaf Coffee,Medium$4.25
250Coffee,Decaf Coffee,Large$4.75

<colgroup><col style="width: 25pxpx"><col><col><col><col><col><col><col><col><col><col></colgroup><thead>
</thead><tbody>
</tbody>
Setup

Worksheet Formulas
CellFormula
F2=IFERROR(INDEX(BevType_list,AGGREGATE(15,6,ROW(BevType_list)-ROW(Setup!$D$1)/(Type_list=BevSelected),ROWS(Setup!$D$2:D2))),0)
F3=IFERROR(INDEX(BevType_list,AGGREGATE(15,6,ROW(BevType_list)-ROW(Setup!$D$1)/(Type_list=BevSelected),ROWS(Setup!$D$2:D3))),0)
F4=IFERROR(INDEX(BevType_list,AGGREGATE(15,6,ROW(BevType_list)-ROW(Setup!$D$1)/(Type_list=BevSelected),ROWS(Setup!$D$2:D4))),0)
F5=IFERROR(INDEX(BevType_list,AGGREGATE(15,6,ROW(BevType_list)-ROW(Setup!$D$1)/(Type_list=BevSelected),ROWS(Setup!$D$2:D5))),0)
F6=IFERROR(INDEX(BevType_list,AGGREGATE(15,6,ROW(BevType_list)-ROW(Setup!$D$1)/(Type_list=BevSelected),ROWS(Setup!$D$2:D6))),0)
F7=IFERROR(INDEX(BevType_list,AGGREGATE(15,6,ROW(BevType_list)-ROW(Setup!$D$1)/(Type_list=BevSelected),ROWS(Setup!$D$2:D7))),0)
F8=IFERROR(INDEX(BevType_list,AGGREGATE(15,6,ROW(BevType_list)-ROW(Setup!$D$1)/(Type_list=BevSelected),ROWS(Setup!$D$2:D8))),0)
F9=IFERROR(INDEX(BevType_list,AGGREGATE(15,6,ROW(BevType_list)-ROW(Setup!$D$1)/(Type_list=BevSelected),ROWS(Setup!$D$2:D9))),0)
F10=IFERROR(INDEX(BevType_list,AGGREGATE(15,6,ROW(BevType_list)-ROW(Setup!$D$1)/(Type_list=BevSelected),ROWS(Setup!$D$2:D10))),0)
F11=IFERROR(INDEX(BevType_list,AGGREGATE(15,6,ROW(BevType_list)-ROW(Setup!$D$1)/(Type_list=BevSelected),ROWS(Setup!$D$2:D11))),0)
F12=IFERROR(INDEX(BevType_list,AGGREGATE(15,6,ROW(BevType_list)-ROW(Setup!$D$1)/(Type_list=BevSelected),ROWS(Setup!$D$2:D12))),0)
F13=IFERROR(INDEX(BevType_list,AGGREGATE(15,6,ROW(BevType_list)-ROW(Setup!$D$1)/(Type_list=BevSelected),ROWS(Setup!$D$2:D13))),0)
F14=IFERROR(INDEX(BevType_list,AGGREGATE(15,6,ROW(BevType_list)-ROW(Setup!$D$1)/(Type_list=BevSelected),ROWS(Setup!$D$2:D14))),0)
F15=IFERROR(INDEX(BevType_list,AGGREGATE(15,6,ROW(BevType_list)-ROW(Setup!$D$1)/(Type_list=BevSelected),ROWS(Setup!$D$2:D15))),0)
F16=IFERROR(INDEX(BevType_list,AGGREGATE(15,6,ROW(BevType_list)-ROW(Setup!$D$1)/(Type_list=BevSelected),ROWS(Setup!$D$2:D16))),0)
F17=IFERROR(INDEX(BevType_list,AGGREGATE(15,6,ROW(BevType_list)-ROW(Setup!$D$1)/(Type_list=BevSelected),ROWS(Setup!$D$2:D17))),0)
F18=IFERROR(INDEX(BevType_list,AGGREGATE(15,6,ROW(BevType_list)-ROW(Setup!$D$1)/(Type_list=BevSelected),ROWS(Setup!$D$2:D18))),0)
F19=IFERROR(INDEX(BevType_list,AGGREGATE(15,6,ROW(BevType_list)-ROW(Setup!$D$1)/(Type_list=BevSelected),ROWS(Setup!$D$2:D19))),0)
F20=IFERROR(INDEX(BevType_list,AGGREGATE(15,6,ROW(BevType_list)-ROW(Setup!$D$1)/(Type_list=BevSelected),ROWS(Setup!$D$2:D20))),0)
F21=IFERROR(INDEX(BevType_list,AGGREGATE(15,6,ROW(BevType_list)-ROW(Setup!$D$1)/(Type_list=BevSelected),ROWS(Setup!$D$2:D21))),0)
F22=IFERROR(INDEX(BevType_list,AGGREGATE(15,6,ROW(BevType_list)-ROW(Setup!$D$1)/(Type_list=BevSelected),ROWS(Setup!$D$2:D22))),0)
F23=IFERROR(INDEX(BevType_list,AGGREGATE(15,6,ROW(BevType_list)-ROW(Setup!$D$1)/(Type_list=BevSelected),ROWS(Setup!$D$2:D23))),0)
F24=IFERROR(INDEX(BevType_list,AGGREGATE(15,6,ROW(BevType_list)-ROW(Setup!$D$1)/(Type_list=BevSelected),ROWS(Setup!$D$2:D24))),0)
F25=IFERROR(INDEX(BevType_list,AGGREGATE(15,6,ROW(BevType_list)-ROW(Setup!$D$1)/(Type_list=BevSelected),ROWS(Setup!$D$2:D25))),0)

<thead>
</thead><tbody>
</tbody>

<tbody>
</tbody>

Workbook Defined Names
NameRefers To
BevSelected=Pulldown!$B$3
BevType_list=OFFSET(Setup!$D$1,1,0,MATCH("zzzzzzzzzz",Setup!$D:$D)-ROW(Setup!$D$1),1)
Type_list=OFFSET(Setup!$D$1,1,1,MATCH("zzzzzzzzzz",Setup!$E:$E)-ROW(Setup!$D$1),1)

<thead>
</thead><tbody>
</tbody>

<tbody>
</tbody>
 
Upvote 0
There is an external link in my workbook and i got the link detail by running a simple macro.

Code:
sub FetchLink()
Dim aLinks As Variant
aLinks = ActiveWorkbook.LinkSources(xlExcelLinks)
If Not IsEmpty(aLinks) Then
Sheets.Add
For i = 1 To UBound(aLinks)
Cells(i, 1).Value = aLinks(i)
Next i
End If
end sub

and by searching the link by name, i find no result the external Link fetched by this macro.
 
Upvote 0

Forum statistics

Threads
1,215,440
Messages
6,124,882
Members
449,193
Latest member
PurplePlop

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top