#1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 54
Default Cell reference

hi

How do I write a cell reference to another sheet, using another cellvalue.
Example
Instead of writing ='sheet2'!A1
Id like to set the name of the "sheet" using the value of another cell.
Seems easy enough but I cant seem to get the syntax right.
Thanks!



  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 2,886
Default Cell reference

Hi Chris

=INDIRECT("'"&X1&"'!A1)
where X1 holds the worksheet name

Note that the quotes are " ' " and " ' ! A1"


--
Regards

Roger Govier


"ChrisP" wrote in message
...
hi

How do I write a cell reference to another sheet, using another
cellvalue.
Example
Instead of writing ='sheet2'!A1
Id like to set the name of the "sheet" using the value of another
cell.
Seems easy enough but I cant seem to get the syntax right.
Thanks!





  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 54
Default Cell reference

thanks alot! worked like a charm.
This created a new problem thol.... is there a quick way to copy this to 100
cells in 1 collumn and increasing A1 by 1.
If I ctrl drag the cell it increases X1 by :(



"Roger Govier" skrev:

Hi Chris

=INDIRECT("'"&X1&"'!A1)
where X1 holds the worksheet name

Note that the quotes are " ' " and " ' ! A1"


--
Regards

Roger Govier


"ChrisP" wrote in message
...
hi

How do I write a cell reference to another sheet, using another
cellvalue.
Example
Instead of writing ='sheet2'!A1
Id like to set the name of the "sheet" using the value of another
cell.
Seems easy enough but I cant seem to get the syntax right.
Thanks!






  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 2,886
Default Cell reference

Hi Chris

Make the X1 absolute by using $X$1

Note the A1 will remain fixed, as it is inside of the quotes.
If you did want the cell reference to alter as you copied down, then you
would need to use

=INDIRECT("'"&$X$1&"'!A"&ROW(A1))
Row(A1) will return 1, but when dragged down it will change to row(A2)
and return 2 and so on, hence the reference will change to A1, A2 etc.

--
Regards

Roger Govier


"ChrisP" wrote in message
...
thanks alot! worked like a charm.
This created a new problem thol.... is there a quick way to copy this
to 100
cells in 1 collumn and increasing A1 by 1.
If I ctrl drag the cell it increases X1 by :(



"Roger Govier" skrev:

Hi Chris

=INDIRECT("'"&X1&"'!A1)
where X1 holds the worksheet name

Note that the quotes are " ' " and " ' ! A1"


--
Regards

Roger Govier


"ChrisP" wrote in message
...
hi

How do I write a cell reference to another sheet, using another
cellvalue.
Example
Instead of writing ='sheet2'!A1
Id like to set the name of the "sheet" using the value of another
cell.
Seems easy enough but I cant seem to get the syntax right.
Thanks!








Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Nesting a sheet name reference within a cell reference??? Broyston Excel Discussion (Misc queries) 9 July 8th 08 08:35 PM
Using an offset formula for the reference in a relative reference Cuda Excel Worksheet Functions 6 November 15th 06 05:12 PM
How do I anchor a cell reference? CasaJay Excel Discussion (Misc queries) 3 June 7th 06 07:12 AM
Possible Lookup Table Karen Excel Worksheet Functions 5 June 8th 05 09:43 PM
Cell Reference Math Ralph Howarth Excel Worksheet Functions 0 January 26th 05 06:27 PM


All times are GMT +1. The time now is 09:54 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"