Forum Discussion

MattMakris's avatar
MattMakris
Qrew Assistant Captain
6 years ago

How to generate date that is exactly one month after numeric field that represents day of month

I am trying to calculate a date that is one month after a date in another field. Here are the fields being used:

  1. Day of the month (numeric field)
  2. Next month start date (date formula)

If the `Day of the month` field is "6" and the current month is March 2020, then `Next month start date` should be "3-6-2020.

Any help on this is much appreciated, thanks!

------------------------------
Matt Makris
------------------------------

2 Replies

  • Conveniently, there is a function for that.

    var date ThisMonthdate = Date(Year(Today()),Month(Today()), [Day of the month]);

    AdjustMonth($ThisMonthdate,1)


    ------------------------------
    Mark Shnier (YQC)
    Quick Base Solution Provider
    Your Quick Base Coach
    http://QuickBaseCoach.com
    mark.shnier@gmail.com
    ------------------------------
    • MattMakris's avatar
      MattMakris
      Qrew Assistant Captain
      That worked perfectly, thank you. The way I was doing it was making the year inaccurate if the current month was December, so this worked out great, thanks!

      Matt

      ------------------------------
      Matt Makris
      ------------------------------