1

I want to fill column names with a sequential list of the last day of each month. For example, 3/31/2018, 4/30/2018, 5/31/2018, etc. Is there a formula that can do this? If cell B1 = 3/31/2018, I tried this:

=DATE(YEAR(B1), MONTH(B1)+1, DAY(B1))

But this produces 5/1/2018 since April has only 30 days.

0

An alternative solution, that looks similar to your original formula, is to use the following:

=date(year(B1),month(B1)+2,0)
0
  • instead of your formula use EOMONTH

    =EOMONTH(B1, 1)

    enter image description here

  • or you can use a single formula to print the whole array:

    =ARRAYFORMULA(EOMONTH(B1, ROW(A1:A11)))

    0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.