LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
trempnvt
 
Posts: n/a
Default Vlookup with variable worksheet reference


Hello,

I'm trying to run a vlookup where the worksheet (within the file)
referenced would depend on the value of a certain cell.

For example, if B5 could be a number different fruits, and there were
different worksheets named after the fruit options, I could have one
cell where I would look up something on worksheet 'Apple' if B5="Apple"
or on worksheet 'Grape' if B5="Grape".

When B5="Apple",
=VLOOKUP(A2,'Apple'!A1:C37,3,FALSE) will give me the correct value, but
both
=VLOOKUP(A2,B5!A1:C37,3,FALSE)
and
=VLOOKUP(A2,'B5'!A1:C37,3,FALSE)
will open a browse window and ask me to update the values for B5.

Any help would be much appreciated.


--
trempnvt
------------------------------------------------------------------------
trempnvt's Profile: http://www.excelforum.com/member.php...o&userid=34710
View this thread: http://www.excelforum.com/showthread...hreadid=544779

 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to use a cell value to reference a worksheet name S2 Excel Worksheet Functions 2 October 10th 05 03:02 PM
dynamic worksheet reference bmccall17 Excel Worksheet Functions 1 September 19th 05 06:46 PM
Reference the worksheet from a multiple worksheet range function ( DBickel Excel Worksheet Functions 1 May 28th 05 03:49 AM
Absolute Worksheet reference number Tony M Excel Discussion (Misc queries) 4 March 21st 05 06:10 PM
make a vlookup using a variable path Alex St-Pierre Excel Worksheet Functions 1 March 2nd 05 11:54 PM


All times are GMT +1. The time now is 12:38 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"