+ Reply to Thread
Results 1 to 2 of 2

Referecing a cell in a Vlookup, without the external spreadsheet needing to be open.

  1. #1
    Registered User
    Join Date
    10-11-2010
    Location
    US
    MS-Off Ver
    NA
    Posts
    41

    Smile Referecing a cell in a Vlookup, without the external spreadsheet needing to be open.



    I have a workbook with 173 references to an external workbook (for simplicity referred to as Source.xls). The workbook has a cell C2 that also references the various spreadsheets in the workbook ranging from 104 to 120. I am looking for a solution to dynamically change the below vlookup as the cell C2 changes within the range from 104 to 120. I tired to program the reference as a CONCATENATE("'[Month to Month Spreadsheet Template.xls]",$A$1,"'!$B$4:$DS$11") and manually with &, but the vlookup did not properly reference the range.

    Here it the base formula for the vlookup: VLOOKUP(F13,'[Source.xls]104'!$B$4:$DS$11,22,0).

    It is critical for this formula to work when the Source.xls is not opened. Thank you in advance for your assistance.

  2. #2
    Forum Expert JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: Referecing a cell in a Vlookup, without the external spreadsheet needing to be op

    CONCATENATE() is the wrong function for this, it's INDIRECT().

    =VLOOKUP(F13,INDIRECT("'[Month to Month Spreadsheet Template.xls]" & $A$1 & "'!$B$4:$DS$11"),22,0)


    Unfortunately this resolves the variable reference in cell A1 getting inserted, but INDIRECT() does require the external document to be open.

    First, get the formula working properly with the external document open so you know you have it right.

    Next, you'll have to install more functionality into your Excel program. Only people with the same installed ADD-IN will be able to use your sheet.

    The ADD-IN is called MoreFunc...read all about it here:
    http://xcell05.free.fr/morefunc/english/

    Download and install it from here:
    http://download.cnet.com/Morefunc/30...-10423159.html

    Go into TOOLS > ADDINS and activate MoreFunc.

    Now you have many, many new functions available to you. Any place you used INDIRECT, now use INDIRECT.EXT instead and it will work on closed workbooks.
    _________________
    Microsoft MVP 2010 - Excel
    Visit: Jerry Beaucaire's Excel Files & Macros

    If you've been given good help, use the icon below to give reputation feedback, it is appreciated.
    Always put your code between code tags. [CODE] your code here [/CODE]

    ?None of us is as good as all of us? - Ray Kroc
    ?Actually, I *am* a rocket scientist.? - JB (little ones count!)

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1