Share via

Excel Formula for creating YTD function

Anonymous
2016-04-15T12:52:21+00:00

I am trying to create a formula to get YTD number, i.e. if presently we are in Period 1, I need total upto Period 1 and if at period 4, total upto period 4. I tried to make the same with formula SUMPRODUCT (As per the attached sheet), but for the same, I have to make an arrangement, that the value C2 to N2 are changing only with an input at A2. Can you please help.

Enter Period Here Formula Below =IF(CONCATENATE("P",A2)=C4,1,0)
1 1 0 0 0 0 0 0 0 0 0 0 0
Actual 15/16 Actual 15/16 Actual 15/16 Actual 15/16 Actual 15/16 Actual 15/16 Actual 15/16 Actual 15/16 Actual 15/16 Actual 15/16 Actual 15/16 Actual 15/16 YTD<br><br><br>FORMULA (=SUMPRODUCT(C2:N2,C5:N5))
P1 P2 P3 P4 P5 P6 P7 P8 P9 P10 P11 P12 P1
1 2 3 4 5 6 7 8 9 10 11 12 1

regards,

Jugdeep

Microsoft 365 and Office | Excel | For home | Windows

Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.

0 comments No comments

Answer accepted by question author

Anonymous
2016-04-15T13:06:33+00:00

Hi Jugdeep G

Please follow the following steps & you should get what your are looking for:

Best Regards

Khalid Suddle

Was this answer helpful?

1 person found this answer helpful.
0 comments No comments

2 additional answers

Sort by: Most helpful
  1. Ashish Mathur 101.9K Reputation points Volunteer Moderator
    2016-04-15T23:48:16+00:00

    Hi,

    Try this

    =SUM(C5:INDEX(C5:N5,1,A2))

    Was this answer helpful?

    0 comments No comments
  2. Anonymous
    2016-04-15T13:29:11+00:00

    Hope I have understood Q correctly

    best wishes

    Was this answer helpful?

    0 comments No comments