Cell reference - for the sheet name, can I use a variable?

M

Matt Lawson

For example, I know I can refer to another worksheet in a cell formula as such:
=Data!C6

However, Is there a way to refer to the name of the sheet based on the name
of the sheet being a variable (ie. the contents of another cell?)

THanks

Matt Lawson
 
M

Matt Lawson

Thanks again for the help Frank!

I get a "formula you typed contains an error".. I did replace A1 with the
correct cell. I looked up the reference in help, and I'm not sure how you are
using the INDIRECT function.

Thanks

Matt Lawson
 
B

Bob Phillips

Matt,

It should be

=INDIRECT("'" & A1 & "'!C6")

not the single quotes as well as the doubles.

--

HTH

RP
(remove nothere from the email address if mailing direct)
 
F

Frank Kabel

Hi Bob
thanks for the correction :)


Bob Phillips said:
Matt,

It should be

=INDIRECT("'" & A1 & "'!C6")

not the single quotes as well as the doubles.

--

HTH

RP
(remove nothere from the email address if mailing direct)
 
Top