Lookup range help

T

Tom

I am trying to find out if there is a way to return a specified column in a
vlookup formula, with a changing selection. For example...

Month Jan Feb Mar Apr

Cust
1 20 15 25 30
2 10 8 30 15
3 45 55 63 49

In my formula I would like the Month column to change, when I specify what
month I am looking for. I am trying to see if I can keep the formula the
same and change the month in an index sheet, and have my lookup reference the
index sheet.
 
S

Sheeloo

You want to change the index in the VLOOKUP?
Change 2 to anything between 1-12 in the formula above?
=VLOOKUP(A1,Sheet!A:M),2,FALSE)

You have many options
Repalce 2 with any cell address say N1 like below
=VLOOKUP(A1,Sheet!A:M),2,FALSE)

or refer to the column no it is
=VLOOKUP(A1,Sheet!A:M),Column(),FALSE)
If you are entering this in Col D then you will get 4 in place of Column()

and so on
You can use INIRECT, INDEX, MATCH... etc to get the desired index.

Hope this is what you were looking for...
 

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