+ Reply to Thread
Results 1 to 4 of 4

vlookup table array until the very last cell with value

  1. #1
    Registered User
    Join Date
    04-16-2013
    Location
    Philippines
    MS-Off Ver
    Excel 2010
    Posts
    3

    vlookup table array until the very last cell with value

    Hi all,

    I am looking into a way that the vlookup table array can be flexible to the very last cell with values.

    For example:

    A1:A10 - this is assuming the value is until A10 and all cells below A10 is blank.

    But my spreadsheet is always changing so sometimes it is upto A20, A30 or less than A10.

    I have considered using A:A which is selecting entire column but due to big file size, excel is running very slow.


    Any suggestions? Thanks in advance!

  2. #2
    Forum Moderator vlady's Avatar
    Join Date
    09-22-2011
    Location
    Philippines - OLSHCO -Guimba-Nueva Ecija
    MS-Off Ver
    2021
    Posts
    4,361

    Re: vlookup table array until the very last cell with value

    don't know if this could help on file size and slowness of excel in your end.

    =VLOOKUP(F4,INDIRECT("B1:C"&MATCH(9.99999999999999E+307,B1:B200)),2,FALSE)
    note the B1-B200...this insure that the match will just go up to 200 rows down

    there are other function aside from match() -lookup also could return the last non blank cell
    LOOKUP(2,1/(B1:B200<>""),B1:B200)
    I think people forget the word "THANK YOU!!!!" Do you still know it???

    There is a little star ( ADD REPUTATION ) below those person who helped you. Click it to say your "PRIVATE APPRECIATION TO THEIR EFFORT ON THEIR CONTRIBUTIONS "

    Regards,
    Vladimir

  3. #3
    Registered User
    Join Date
    04-16-2013
    Location
    Philippines
    MS-Off Ver
    Excel 2010
    Posts
    3

    Re: vlookup table array until the very last cell with value

    Hi Vlady, thanks for the help I think the vlookup formula you gave me might be the key.

    just to clarify what does the "B1:C" stands for in the vlookup formula?

    =VLOOKUP(F4,INDIRECT("B1:C"&MATCH(9.99999999999999E+307,B1:B200)),2,FALSE)

  4. #4
    Forum Expert
    Join Date
    08-12-2012
    Location
    Sydney, Australia
    MS-Off Ver
    Excel 2010
    Posts
    5,636

    Re: vlookup table array until the very last cell with value

    its forms part of the table array
    MATCH gives you last row
    INDIRECT must be included or else the formula doesn't work

    if there is 16 rows
    B1:C16 is your table array

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Tags for this Thread

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