HLOOKUP Question

trainer75

New Member
Joined
Jun 11, 2015
Messages
33
Hi,

Hope some one can assist me with this.

I am trying to do a HLOOKUP from data like below

13/14 P13W313/14 P13W414/15 P1W114/15 P1W2
Bread46555433
Rolls28224212
Butter66575869

<tbody>
</tbody>

On another tab I have a drop down box to select the period/week and I then want it to bring back the data related to the date and the item (like below)

14/15 P1W1
Bread54
Rolls42
Butter58

<tbody>
</tbody>

What I have as a formula but keep getting #Ref!

=IF(ISNA(VLOOKUP($B$1,INDIRECT($A1&"!A:K"),11,0)=TRUE),0,VLOOKUP($B$1,INDIRECT($A1&"!A:K"),11,0))

B1 is selecting the Date and the items are in column A from row 21 to 25

Hope this makes sense

Thanks in advance
 

Excel Facts

How can you automate Excel?
Press Alt+F11 from Windows Excel to open the Visual Basic for Applications (VBA) editor.
what about an index/match solution?


Excel 2012
ABCDE
113/14 P13W313/14 P13W414/15 P1W114/15 P1W2
2Bread46555433
3Rolls28224212
4Butter66575869
5
614/15 P1W1
7Bread54
8Rolls42
9Butter58
Sheet1
Cell Formulas
RangeFormula
B7=INDEX($B$2:$E$4,MATCH($A7,$A$2:$A$4,0),MATCH(B$6,$B$1:$E$1,0))
 
Upvote 0
what about an index/match solution?

Excel 2012
ABCDE
113/14 P13W313/14 P13W414/15 P1W114/15 P1W2
2Bread46555433
3Rolls28224212
4Butter66575869
5
614/15 P1W1
7Bread54
8Rolls42
9Butter58

<colgroup><col><col><col><col><col><col></colgroup><thead>
</thead><tbody>
</tbody>
Sheet1

Worksheet Formulas
CellFormula
B7=INDEX($B$2:$E$4,MATCH($A7,$A$2:$A$4,0),MATCH(B$6,$B$1:$E$1,0))

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

<tbody>
</tbody>




That is superb,

Thank you very much for your quick reply.

I hadn't thought of index and match.

Thanks again :)
 
Upvote 0

Forum statistics

Threads
1,215,799
Messages
6,126,976
Members
449,351
Latest member
Sylvine

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