Sabbib
Sabbib

Reputation: 47

How do I use a row value as a variable to refer to an address in excel

I have a cell that uses match function to find the location from a column and I want to use that location value to refer to another column.

For example:

How would i do that?

Upvotes: 1

Views: 48

Answers (2)

Darren Bartrup-Cook
Darren Bartrup-Cook

Reputation: 19737

INDEX would be a better method - INDIRECT is volatile, while INDEX isn't.
=INDEX($E:$E,MATCH(223,$D:$D, 0)) or =INDEX($E:$E,$G$1) (return a reference to the 49th row in column E).

http://chandoo.org/wp/2014/03/03/handle-volatile-functions-like-they-are-dynamite/

Upvotes: 0

Dawid SA Tokyo
Dawid SA Tokyo

Reputation: 376

What you could try is an INDIRECT function.

Try this in cell G2:
=INDIRECT("E"&G1)

Upvotes: 2

Related Questions