Vlookup - to change column lookup automatically

CDNWolf

Board Regular
Joined
Nov 14, 2010
Messages
71
Office Version
  1. 365
Platform
  1. Windows
Hi guys,

Couldn't find an answer online so here I am...

All I want is to copy this cell down or across to automatically look in the next column without manually typing it out
I have over 150 columns to look at so not ideal to change the column number manually for each formula

This is what I am doing manually.
=VLOOKUP(Sheet1!$A$2,Range2,2,FALSE)
=VLOOKUP(Sheet1!$A$2,Range2,3,FALSE)
=VLOOKUP(Sheet1!$A$2,Range2,4,FALSE)
=VLOOKUP(Sheet1!$A$2,Range2,5,FALSE)
=VLOOKUP(Sheet1!$A$2,Range2,6,FALSE)

Not sure if Match or Column can be used in this formula.
FYI Range2 = =$C$4:$DV$13 if that helps

Thanks in advance for your help
 

Excel Facts

Create a chart in one keystroke
Select the data and press Alt+F1 to insert a default chart. You can change the default chart to any chart type
If you want to copy it down you could use ROW() for the column number (adjust as needed depending on location of the formula) and to copy across you could use COLUMN(). It would be more efficient to use INDEX and MATCH so you only do the lookup once.
 
Upvote 0
If you want to copy it down you could use ROW() for the column number (adjust as needed depending on location of the formula) and to copy across you could use COLUMN(). It would be more efficient to use INDEX and MATCH so you only do the lookup once.
Can you plug in your suggestion, so I see what you mean?
 
Upvote 0
So one MATCH formula to lookup the value:

Excel Formula:
=MATCH(Sheet1!$A$2,$C$4:$C$13,0)
let's say that is in B2. Then multiple index formulas use that value directly:

Excel Formula:
=INDEX(D$4:D$13,$B$2)

and just copy across as needed.
 
Upvote 0
So one MATCH formula to lookup the value:

Excel Formula:
=MATCH(Sheet1!$A$2,$C$4:$C$13,0)
let's say that is in B2. Then multiple index formulas use that value directly:

Excel Formula:
=INDEX(D$4:D$13,$B$2)

and just copy across as needed.

I did find a way around it...

In Column B (on a deferent sheet, I numbered the rows down from 1 - 150 and used that reference in my formula;
=VLOOKUP(Sheet1!$A$2,Range2,B2,FALSE) Because B2 = 1, it will look at column 1 in Range2
=VLOOKUP(Sheet1!$A$2,Range2,B3,FALSE) Because B3 = 2, it will look at column 2 in Range2
=VLOOKUP(Sheet1!$A$2,Range2,B4,FALSE) Because B4 = 3, it will look at column 3 in Range2

Thanks again for your suggestion. I couldn't be bothered to manually change the column numbers manually for each lookup, so time consuming
 
Upvote 0
What are you looking to accomplish with your VLOOKUP formulas? There may be a better option.
 
Upvote 0
What are you looking to accomplish with your VLOOKUP formulas? There may be a better option.

I'm sure there is another solution but as mentioned in my last reply, my solution worked well.

Cheers
 
Upvote 0
I couldn't be bothered to manually change the column numbers manually for each lookup, so time consuming
My suggestion didn't require that and would have avoided looking up the same information repeatedly as your current version does. ;)
 
Upvote 0

Forum statistics

Threads
1,214,867
Messages
6,122,002
Members
449,059
Latest member
mtsheetz

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