![]() |
Logic breakdown.
I'm looping through a variable number of row finding each unique value and
posting it on antoher sheet. I then want to create another table with 36 different calculations referencing two of the copied cells. They need to be arranged like below. Bobby Sue Form1(Cell 1) Form2(Cell 1) Form3(Cell 1) Form1(Cell 2) Form2(Cell2) Form2(Cell2) etc. I've got: x = 0 For a = 1 to ALLROWS If cell1.value is unique then ========This is a whole sting of if statements actually and I won't bore you with them x = x + 1 Copy cells a-f 1newsheet paste 2newsheet paste column a cell cell(B"+Cstr(x)).formulaR1C1 = "=sum(1newsheet!cellR[x]C[1]). cell cell(c"+Cstr(x)).formulaR1C1 = "=sum(1newsheet!cellR[x]C[0]). cell cell(d"+Cstr(x)).formulaR1C1 = "=sum(1newsheet!cellR[x]C[-1]). cell cell(e"+Cstr(x)).formulaR1C1 = "=sum(1newsheet!cellR[x]C[-1]). cell cell(e"+Cstr(x)).formulaR1C1 = "=sum(1newsheet!cellR[x]C[-2]). cell cell(e"+Cstr(x)).formulaR1C1 = "=sum(1newsheet!cellR[x]C[-3]). <<<<should repeat through 36 Next a I dont' want to write that many lines of forumlas and I know there's some mathmatical correlation but it's just eluding me today. It's the column reference that's giving me fits. It's a mutiple of 3 but it repeats on the first instance (the 3rd formula is -1 and the forth is also -1). This is probably an even solution for you guys. Help! |
Logic breakdown.
Oops, there's twelve cells that are referenced and not 2.
Can I start the week over? "RominallL" wrote: I'm looping through a variable number of row finding each unique value and posting it on antoher sheet. I then want to create another table with 36 different calculations referencing two of the copied cells. They need to be arranged like below. Bobby Sue Form1(Cell 1) Form2(Cell 1) Form3(Cell 1) Form1(Cell 2) Form2(Cell2) Form2(Cell2) etc. I've got: x = 0 For a = 1 to ALLROWS If cell1.value is unique then ========This is a whole sting of if statements actually and I won't bore you with them x = x + 1 Copy cells a-f 1newsheet paste 2newsheet paste column a cell cell(B"+Cstr(x)).formulaR1C1 = "=sum(1newsheet!cellR[x]C[1]). cell cell(c"+Cstr(x)).formulaR1C1 = "=sum(1newsheet!cellR[x]C[0]). cell cell(d"+Cstr(x)).formulaR1C1 = "=sum(1newsheet!cellR[x]C[-1]). cell cell(e"+Cstr(x)).formulaR1C1 = "=sum(1newsheet!cellR[x]C[-1]). cell cell(e"+Cstr(x)).formulaR1C1 = "=sum(1newsheet!cellR[x]C[-2]). cell cell(e"+Cstr(x)).formulaR1C1 = "=sum(1newsheet!cellR[x]C[-3]). <<<<should repeat through 36 Next a I dont' want to write that many lines of forumlas and I know there's some mathmatical correlation but it's just eluding me today. It's the column reference that's giving me fits. It's a mutiple of 3 but it repeats on the first instance (the 3rd formula is -1 and the forth is also -1). This is probably an even solution for you guys. Help! |
All times are GMT +1. The time now is 05:35 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com