+ Reply to Thread
Results 1 to 7 of 7

Vlookup Against Value In First Visible Cell

  1. #1
    Registered User
    Join Date
    03-14-2006
    Posts
    46

    Vlookup Against Value In First Visible Cell

    I have a filtered list in excel and say the first row of filtered data was A400. how can I do a lookup against this first cell. Obviously every time I filter against a different part nmber the first row changes.

    macke

  2. #2
    Domenic
    Guest

    Re: Vlookup Against Value In First Visible Cell

    Assumptions:

    A2:C10 contains the data

    E1 contains the lookup value

    The corresponding value in Column C is to be returned

    Formula:

    =VLOOKUP(E1,IF(SUBTOTAL(3,OFFSET(A2:A10,ROW(A2:A10)-ROW(A2),0,1)),A2:C10)
    ,3,0)

    ....confirmed with CONTROL+SHIFT+ENTER, not just ENTER.

    Hope this helps!

    In article <macke.26gpgc_1145367306.2282@excelforum-nospam.com>,
    macke <macke.26gpgc_1145367306.2282@excelforum-nospam.com> wrote:

    > I have a filtered list in excel and say the first row of filtered data
    > was A400. how can I do a lookup against this first cell. Obviously
    > every time I filter against a different part nmber the first row
    > changes.
    >
    > macke


  3. #3
    Registered User
    Join Date
    03-14-2006
    Posts
    46

    Not Quite Right

    Hi

    The formula works fine, but I guess my requirement wasn't quite clear.

    I need the to use the value in the first cell as my lookup value to be able to extract the data from another spreadsheet.

    Sorry

    macke

  4. #4
    Domenic
    Guest

    Re: Vlookup Against Value In First Visible Cell

    To return the first visible value in a filtered list, try...

    =INDEX(A2:A100,MATCH(1,SUBTOTAL(3,OFFSET(A2:A100,ROW(A2:A100)-ROW(A2),0,1
    )),0))

    ....confirmed with CONTROL+SHIFT+ENTER, not just ENTER. Then, use this
    as the lookup value for the lookup formula.

    Hope this helps!

    In article <macke.26ipg0_1145460601.9995@excelforum-nospam.com>,
    macke <macke.26ipg0_1145460601.9995@excelforum-nospam.com> wrote:

    > Hi
    >
    > The formula works fine, but I guess my requirement wasn't quite clear.
    >
    > I need the to use the value in the first cell as my lookup value to be
    > able to extract the data from another spreadsheet.
    >
    > Sorry
    >
    > macke


  5. #5
    Registered User
    Join Date
    03-14-2006
    Posts
    46

    Re: Vlookup Against Value In First Visible Cell

    Hi

    Yes that works brilliantly. Thank you

    macke

  6. #6
    Registered User
    Join Date
    09-11-2012
    Location
    Woodstock, Canada
    MS-Off Ver
    Excel 2007
    Posts
    6

    Re: Vlookup Against Value In First Visible Cell

    Hi,

    I am also i need of this formula.
    However, I am not familiar with complex formulas such as these. The formula worked for returning the value of A2 in the filtered list. I also need the value for A3, A4 etc. so what part of the formula do i change for this?
    Thanks

  7. #7
    Forum Contributor arlu1201's Avatar
    Join Date
    09-09-2011
    Location
    Bangalore, India
    MS-Off Ver
    Excel 2003 & 2007
    Posts
    19,167

    Re: Vlookup Against Value In First Visible Cell

    drystorm,

    Welcome to the Forum, unfortunately:

    Your post does not comply with Rule 2 of our Forum RULES. Don't post a question in the thread of another member -- start your own thread. If you feel it's particularly relevant, provide a link to the other thread. It makes sense to have a new thread for your question because a thread with numerous replies can be off putting & difficult to pick out relevant replies.
    If I have helped, Don't forget to add to my reputation (click on the star below the post)
    Don't forget to mark threads as "Solved" (Thread Tools->Mark thread as Solved)
    Use code tags when posting your VBA code: [code] Your code here [/code]

+ 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