# Combox1 & Combobox2 equals specific cell

#### MerryMaca

##### New Member
Hello!
I don't know how to name this thread but I tried my best . I am new at excel so I have a lot to learn. But so far I have managed to use VLOOKUP and managed to set a Combobox1(wich are rows) with list that I want (A15:A500).
What I have problem with is that I want Combobox2 that I want to have two specific cells that I can choose between no matter what I choose in Combobox1. Then I want to have a result based from what I've choosen. So result will be in a Textbox1 (wich is specific cell from row and cell choosen in comboboxes).

For e.g. Combobox1: Bergdalen(A20) + Combobox2: Boggibil(C13) equals Textbox1: 342,00 kr(D20)

Here is a picture to make it more clear:

### Excel Facts

Best way to learn Power Query?
Read M is for (Data) Monkey book by Ken Puls and Miguel Escobar. It is the complete guide to Power Query.
This is what I understand.

If Combobox2 is "Boggibil", you want to return a value from column D. If Combobox2 is "Bil & Slap", you want to return a value from column F. Is that correct?

Put this formula in cell C1
Code:
``=IF(OR(A1="",B1=""),"",INDEX(OFFSET(A15:A500,,IF(B1="Boggibil", 3,5)),MATCH(A1,A15:A500,0)))``

The formula will calculate a value for your text box. If A1 or B1 is empty, then c1 will be empty. Otherwise it looks up the value from A1 in A15:A500 and then returns the value for column D or F depending on what is in cell B1.

Hi Alpha,
yes ... that's exactly what I want. But D column is a result from B + C and F column is a result from B + E
... and I'm not at all good at codes ... what I did in combobox1 is that I changed ListFillRange to Område1!A15:A500(Sheet1 is "Område"), that is what I managed to do so far... but I would really like to learn, and I did learn a lot on this forum

What I had in mind is to have a combobox1 with list from column that begins from A5 and combobox2 with just cells C14 & E14 so if I choose a column(combobox1) and a row(combobox2) that it automaticlly shows in a textbox1 a result from multiplying those two .. I did multiply those separate in columns D & F to make it easier for me
But to make it work I need help with coding

P.S. .. my version is in Swedish.

Replies
0
Views
185
Replies
6
Views
285
Replies
2
Views
201
Replies
4
Views
183
Replies
0
Views
318

1,217,507
Messages
6,137,033
Members
450,041
Latest member
MM2024

### 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.

### Which adblocker are you using?

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

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