Appreciate any help on how to elegant sum for a quarter given the date (or specified quarter number). I can create a switch simply by the quarter number (just hardcoded 1s below) but there might be an easier way? I would need to also average it. Really appreciate any pointers!
MrExcel.xlsx | |||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
C | D | E | F | G | H | I | J | K | L | M | N | O | P | Q | |||
1 | Report Month | 7 | |||||||||||||||
2 | Report Quarter | 3 | |||||||||||||||
3 | Report Year | 2024 | |||||||||||||||
4 | End of Month | 07/31/24 | |||||||||||||||
5 | |||||||||||||||||
6 | 1 | 1 | 1 | ||||||||||||||
7 | Jan-24 | Feb-24 | Mar-24 | Apr-24 | May-24 | Jun-24 | Jul-24 | Aug-24 | Sep-24 | Oct-24 | Nov-24 | Dec-24 | 2024 | ||||
8 | TOTAL | ||||||||||||||||
9 | |||||||||||||||||
10 | ENERGY MARGIN | ||||||||||||||||
11 | 600100 | REVENUE - ENERGY SALES | - | - | - | - | - | - | - | - | - | - | - | - | - | ||
12 | 600105 | REVENUE - ENERGY - REAL TIME | - | - | - | - | - | - | - | - | - | - | - | - | - | ||
13 | 600110 | REVENUE - ENERGY - DAY AHEAD | 483,987 | 751,160 | 709,401 | 828,741 | 585,281 | 1,095,814 | 2,259,505 | 2,102,308 | 1,135,976 | 681,805 | 1,064,370 | 681,291 | 12,379,639 | ||
14 | |||||||||||||||||
15 | |||||||||||||||||
16 | |||||||||||||||||
17 | Q3 | ||||||||||||||||
Sheet1 |
Cell Formulas | ||
---|---|---|
Range | Formula | |
D2 | D2 | =ROUNDUP(D1/3,0) |
D4 | D4 | =EOMONTH(DATE(D3,D1,1),0) |
Cells with Conditional Formatting | ||||
---|---|---|---|---|
Cell | Condition | Cell Format | Stop If True | |
D4 | Expression | =#REF!<>0 | text | YES |