Greetings All, new to this forum and first post. Been coding Excel formula's for 20 years and this one has me stumped. Coming to the experts for some help. TIA.
Trying to do a YTD total for rainfall. Using this formula:
=IF(N19=0, "",
IF(YEAR(A19)<>YEAR(A18), "",
IF(N19=0, O18,
SUMIFS(N:N,A:A, ">="&DATE(YEAR(A19), 1, 1),A:A, "<="&A19))))
Generates good numbers in most cases. See attachment excel-1.jpg.
Column N is where I enter the weekly rainfall total from my rain gauge. Column O shows the YTD total rainfall.
The glitch occurs when it's the first week of the year AND there is a non-zero rainfall to enter in comun N.
See attachment excel-2.jpg.
I'm thinking I might need an IF/AND expression but can't find the right code. Any help is most appreciated.
-Dan
Trying to do a YTD total for rainfall. Using this formula:
=IF(N19=0, "",
IF(YEAR(A19)<>YEAR(A18), "",
IF(N19=0, O18,
SUMIFS(N:N,A:A, ">="&DATE(YEAR(A19), 1, 1),A:A, "<="&A19))))
Generates good numbers in most cases. See attachment excel-1.jpg.
Column N is where I enter the weekly rainfall total from my rain gauge. Column O shows the YTD total rainfall.
The glitch occurs when it's the first week of the year AND there is a non-zero rainfall to enter in comun N.
See attachment excel-2.jpg.
I'm thinking I might need an IF/AND expression but can't find the right code. Any help is most appreciated.
-Dan