vlookup, concatenated named range

P

patti

My function:

=VLOOKUP(G7,"Asset"&F7,1,FALSE)

"Asset"&F7 is a concatenation for a named range. If i type in manually, it
works. Concatenated, it does not.

Why does this not work? Not sure how or if to use indirect or offset.
 
M

Mike H

Patti,

Try this
=VLOOKUP(G7,INDIRECT("Asset"&F7),1,FALSE)
--
Mike

When competing hypotheses are otherwise equal, adopt the hypothesis that
introduces the fewest assumptions while still sufficiently answering the
question.
 
T

T. Valko

Why does this not work?

Let's assume F7 = 2009

"Asset"&F7 = "Asset2009". When you concatenate you're creating a *TEXT*
string. Even though you may have a valid named range called Asset2009 these
are not the same thing.

INDIRECT will convert a TEXT representation of a reference into a valid
reference that can be used as function arguments.

=VLOOKUP(G7,INDIRECT("Asset"&F7),1,0)

This will not work if the named range is a dynamic range defined with
functions like OFFSET.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top