#1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 6
Default Copying Formulas

I'm copying a formula that gets its values from a different worksheet and the
values are not from a serielised range. How can I write it so that the values
automatically pick up which cells to refer to? i.e
if CELL E6 has formula:
IF(SUM('Sheet1'!E$6:G$6) 0,SUM('Sheet1'!E$6:G$6),"")

CELL E7 should have :
=IF(SUM('Sheet1'!H$6:J$6) 0,SUM('Sheet1'!H$6:J$6),"")

CELL E8 should have :
=IF(SUM('Sheet1'!K$6:M$6) 0,SUM('Sheet1'!K$6:M$6),"")

so thats E:G, H:J, K:M etc



--
Wether you think you can or you think you cant , you are right ... anon
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,651
Default Copying Formulas

As you've described it, you've got a circular reference in E6, but if you
put the formula in D6 (for example) you can use
=IF(SUM(OFFSET(Sheet1!E$6,0,3*(ROW()-6),1,3))
0,SUM(OFFSET(Sheet1!E$6,0,3*(ROW()-6),1,3)),"")
and copy that down.
--
David Biddulph

"Mtabaruka" wrote in message
...
I'm copying a formula that gets its values from a different worksheet and
the
values are not from a serielised range. How can I write it so that the
values
automatically pick up which cells to refer to? i.e
if CELL E6 has formula:
IF(SUM('Sheet1'!E$6:G$6) 0,SUM('Sheet1'!E$6:G$6),"")

CELL E7 should have :
=IF(SUM('Sheet1'!H$6:J$6) 0,SUM('Sheet1'!H$6:J$6),"")

CELL E8 should have :
=IF(SUM('Sheet1'!K$6:M$6) 0,SUM('Sheet1'!K$6:M$6),"")

so thats E:G, H:J, K:M etc



--
Wether you think you can or you think you cant , you are right ... anon



  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 3,365
Default Copying Formulas

This is a little difficult for me to explain, but I think you'll see in the
formulas below that the key to this is knowing 2 things:
#1 - the row that your first IF(SUM( formula is on (row 6 in your example
since you say that formula is in E6
#2 - the number of columns you need to move over on the source sheet with
each row you move down on the sheet with your formulas in it: 3 columns each
time - E to H, H to K

Your first formula remains the same, but for the formulas in E8 and E9, you
need to use this format for the
SUM() portions within the IF statements:
SUM(OFFSET('Sheet1'!E$6:G$6,0,(ROW()-ROW(E$6))*3))

So the formula in E7 on your sheet becomes
=IF(SUM(OFFSET('Sheet1'!E$6:G$6,0,(ROW()-ROW(E$6))*3))
0,SUM(OFFSET('Sheet1'!E$6:G$6,0,(ROW()-ROW(E$6))*3)),"")

and oddly enough, that's exactly what your formula in E8 on that sheet
should look like and any more like it in the rows immediately following.

"Mtabaruka" wrote:

I'm copying a formula that gets its values from a different worksheet and the
values are not from a serielised range. How can I write it so that the values
automatically pick up which cells to refer to? i.e
if CELL E6 has formula:
IF(SUM('Sheet1'!E$6:G$6) 0,SUM('Sheet1'!E$6:G$6),"")

CELL E7 should have :
=IF(SUM('Sheet1'!H$6:J$6) 0,SUM('Sheet1'!H$6:J$6),"")

CELL E8 should have :
=IF(SUM('Sheet1'!K$6:M$6) 0,SUM('Sheet1'!K$6:M$6),"")

so thats E:G, H:J, K:M etc



--
Wether you think you can or you think you cant , you are right ... anon

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
Copying formulas DQ1 Excel Discussion (Misc queries) 3 August 31st 05 06:16 PM
Copying Formulas sccspires Excel Worksheet Functions 1 June 10th 05 01:33 AM
copying formulas Mark Goodwin Excel Worksheet Functions 2 May 11th 05 05:31 PM
copying formulas Boz Excel Worksheet Functions 1 March 1st 05 06:47 PM
Copying Down Formulas Q John Excel Worksheet Functions 4 November 23rd 04 11:14 PM


All times are GMT +1. The time now is 01:11 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"