Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5
Default Referencing a cell in another sheet through the use of variables

Hi,

I have a cell which refers to a cell in a different sheet like the
following:

='SheetB'!N5

Now, N is a variable which is the content of another cell (say H10),
and 5 is the actual row of the cell.
I am trying to use string concat so that the cell can display the
result of 'SheetB'!(Content of H10)(Row) but I am not having much
luck.

Which formula should I create ?

Thanks/Brgds
Joćo
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 35,218
Default Referencing a cell in another sheet through the use of variables

I think:

If H10 contains N5, then:
=indirect("'sheetb'!"&h10)

If H10 contained N, then:
=indirect("'sheetb'!"&h10&"5")

You could even refer to a different cell for all those pieces:

=indirect("'" & x99 & "'!" & z1000 & w1234)



JJ wrote:

Hi,

I have a cell which refers to a cell in a different sheet like the
following:

='SheetB'!N5

Now, N is a variable which is the content of another cell (say H10),
and 5 is the actual row of the cell.
I am trying to use string concat so that the cell can display the
result of 'SheetB'!(Content of H10)(Row) but I am not having much
luck.

Which formula should I create ?

Thanks/Brgds
Joćo


--

Dave Peterson
  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 8
Default Referencing a cell in another sheet through the use of variables

=Indirect()?

= "text" & cellref & "text" & number
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
Problem referencing a cell using 2 variables [email protected] Excel Programming 1 August 8th 08 11:45 AM
Sheet referencing in a cell velvetlady Excel Discussion (Misc queries) 1 April 1st 08 06:24 PM
cell referencing with variables Liesbeth Excel Programming 2 March 9th 07 01:07 PM
referencing a sheet named in a cell then using data from that sheet gbeard Excel Worksheet Functions 4 April 15th 05 08:42 AM
Referencing a cell containing sheet name Marcotte A[_2_] Excel Programming 3 May 20th 04 11:26 PM


All times are GMT +1. The time now is 06:58 PM.

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

About Us

"It's about Microsoft Excel"