我想在工作表中每7行总和,并将总和放在不同的列&行 [英] I want to sum every 7 rows in a worksheet and put the sum in different column & rows

查看:106
本文介绍了我想在工作表中每7行总和,并将总和放在不同的列&行的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我从来没有真正使用Excel,但这似乎应该是可能的。



我有一个正在进行的文档,我将每天添加值,但是什么我想要为每7行做一次,我希望它总和这些值,并将7行的总和添加到不同的列/行,例如



行B7 :B14总和在D12中

行B15:B22总和在D13中



然后当我开始向B23添加数据时,我想要添加总和到D14。

解决方案

在D12中,将

  = SUM(OFFSET($ B $ 7,(ROW() -  12)* 8,0,8,1))

,并按照需要填写列D。请注意,B7:B14真的是8行,而不是7.如果你真的想要7行(B7:B13),那么将公式中的两个8改为7。


I have never really used Excel before but this seems like it should be possible.

I have an ongoing document where I will be adding values every day, but what I want it to do for every 7 rows I want it to sum those values and add the sum of the 7 rows to a different column/row, e.g.,

Row B7:B14 Sum in D12
Row B15:B22 Sum in D13

And then when I start adding data into B23 I want it to add the sum to D14.

解决方案

In D12, put

=SUM(OFFSET($B$7,(ROW()-12)*8,0,8,1))

and fill down column D as far as you want. Note that B7:B14 is really 8 rows, not 7. If you really want 7 rows (B7:B13), then change the two 8's to 7's in the formula.

这篇关于我想在工作表中每7行总和,并将总和放在不同的列&行的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆