# Ongoing YTD totals

#### Humble Newbie

##### New Member
Good afternoon!

Column A contains dates going back 5 years, from row 10 downwards, and column C contains numerical values for those dates. Dates are being added almost every day.

What I want to do is sum the values for the current year to date, whatever that happens to be i.e. when 2006 comes around Excel will know it's a new year and start subtotalling again.

Is this possible?

### Excel Facts

Bring active cell back into view
Start at A1 and select to A9999 while writing a formula, you can't see A1 anymore. Press Ctrl+Backspace to bring active cell into view.
Can you use something like:

=If(Year(cell_ref)=Year(today()),do if true, do if false)

Hello NBVC, thank you for replying.

I don't really understand your formula I'm afraid!

If I want the subtotal for the current year, say in A1, do I just enter: =If(Year(A1)=Year(today()),do if true, do if false) ?

Sorry but I'm pretty inexperienced with all this.

Hi,

I think for what you have told me in your initial post, something like this is what you need:

=SUM(IF(YEAR(A1:A100)=YEAR(TODAY()),C1:C100)),

Where A1:A100 contains the dates and C1:C100 contains the numbers. Adjust as necessary.

Note: To confirm the formula use CTRL+SHIFT+ENTER instead of just ENTER.

Hope this helps.

That worked great - thank you very much!

Replies
9
Views
208
Replies
2
Views
362
Replies
2
Views
398
Replies
1
Views
193
Replies
7
Views
676

1,217,673
Messages
6,137,917
Members
450,098
Latest member
Ikmal Sabri

### We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.

### Which adblocker are you using?

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

### Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

### Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back