问题
I have a sheet for every day in the month. At the end of every month, I need to sum the same cell across all tabs. The following works:
=SUM(March31!L2,March30!L2,March29!L2,March28!L2,March26!L2,March25!L2,March24!L2)
However, at the end of the month, the formula will be tremendous. Tried the following:
=SUM(March31:March1!L2)
Doesn't work. Is it even possible?
回答1:
SUM(March31:March1!L2)
that won't work, but you can use kind of a generator:
={" "; ARRAYFORMULA("=SUM("&TEXTJOIN(", ", 1, TEXT(ROW(INDIRECT(
DATEVALUE("2020/01/01")&":"&DATEVALUE("2020/12/31"))), "mmmmd!L2"))&")")}
which will give you the full formula you need so all you need to do is copy-paste the cell bellow
spreadsheet demo
来源:https://stackoverflow.com/questions/61001345/sum-the-same-cell-across-the-sheets-in-google-sheets