Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1
Default Calling name of Sheet as a Variable?

I'm working on a home budget, and I've made 26 sheets (labeled 1-26, aptly).
Each of the sheets calls the previous information from the other sheets, and
if I change something (say add a cost of 100 dollars to one column), it
retroactively affects the other sheets. It took a long time for me to
physically go in and change the equations on each sheet to call the previous
sheet - every time i have to make a change, i have to change 26 sheets.

Example:
= '1'!F20 + D20 - E20 on '2'
= '2'!F20 + D20 - E20 on '3'
etc...

I was wondering if there was a way to call the name of the current sheet as
a variable in an equation, in such that I could write an equation like this:

= '('currentsheet' - 1)'!F20 + D20 - E20

That way I could simply use the same equation in all 25 sheets following
sheet 1. Is there such a way?
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,533
Default Calling name of Sheet as a Variable?

Hi

You can use the INDIRECT function.

In A1 of current sheet enter sheet name of previous sheet, and use a formula
like this:

=INDIRECT(A1 & "!F20")+D20-E20

Hopes this helps.
....
Per

"thekeytothedoor" skrev i
meddelelsen ...
I'm working on a home budget, and I've made 26 sheets (labeled 1-26,
aptly).
Each of the sheets calls the previous information from the other sheets,
and
if I change something (say add a cost of 100 dollars to one column), it
retroactively affects the other sheets. It took a long time for me to
physically go in and change the equations on each sheet to call the
previous
sheet - every time i have to make a change, i have to change 26 sheets.

Example:
= '1'!F20 + D20 - E20 on '2'
= '2'!F20 + D20 - E20 on '3'
etc...

I was wondering if there was a way to call the name of the current sheet
as
a variable in an equation, in such that I could write an equation like
this:

= '('currentsheet' - 1)'!F20 + D20 - E20

That way I could simply use the same equation in all 25 sheets following
sheet 1. Is there such a way?


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
How to add formula calling up current workbook when sheet copied Smudge Excel Discussion (Misc queries) 6 September 7th 07 10:40 AM
Calling a Userform from a Predefined Variable [email protected] Excel Worksheet Functions 0 April 21st 07 03:44 PM
Calling a procudure through variable name Basu Excel Discussion (Misc queries) 2 August 30th 06 08:55 AM
calling variable within string [email protected] Excel Worksheet Functions 8 May 4th 06 03:07 PM
Calling a bit of code from a sheet errors gearoi Excel Discussion (Misc queries) 2 September 6th 05 08:21 PM


All times are GMT +1. The time now is 04:21 AM.

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"