HLOOKUP() to return heading cells

F

FARAZ QURESHI

Cells A1:F1 consists of headings:
Class-I; Class-II; Class-III; Class-IV; Class-V; Class-VI;

Cells A2:F13 consists unit price of every Class during each of the 12 months.

I want to insert a formula in H2:H13 which shall consider the corresponding
Value in G2:G13, lookup in the respective cells of the same row in columns
A:F and return the EXACT relevant Class Heading from A1:F1.
 
F

FARAZ QURESHI

Max! U r the best no doubt!
However, can you explain how does this formula work?
The part MATCH(G2,A2:F2,0) has been inserted in the Row_Num, instead of
Col_Num?
The formula as per the F1 help should have been
=INDEX(A$1:F$1,1,MATCH(G2,A2:F2,0))? Don't you think so?
Need your expert guidance in this regard!

Thanx again!
 
M

Max

Think its optional ..

From Excel's Help
INDEX(array,row_num,column_num)
If array contains only one row or column,
the corresponding row_num or column_num argument is optional.

In H2: =INDEX(A$1:F$1,,MATCH(G2,A2:F2,0))
would have worked just as well
--
Max
Singapore
http://savefile.com/projects/236895
Downloads:20,000 Files:362 Subscribers:62
xdemechanik
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top