endDate ( theDate ; months )
Calc the end date based on number of months to preserve the day of month.
Average rating: 4.8 (28 votes) Log in to vote
Timothy Brown - Show more from this author
Antidote Solutions http://www.antidotesolutions.com |
Function definition: (Copy & paste into FileMaker's Edit Custom Function window)
This solves the problem of alway billing an item on the same day each month. We capture for the days that may be the last day of the month.
If we always bill on the 30th of each month. Then when we get to February, it will calculate the 28th, instead of March 2nd. This calculation is different then the last day of the month, because it allows you to pick the day of the month to always repeat.
Comments
Jack Rodgers, FmpApps May 18, 2011 |
||
Try verifying this for 28, 29, 30, 31 for various months, especially February. Also, check for leap years. For these one must determine what to do such as if the date is the 31 but the last day of the chosen month is 28, 29 or 30. A typical problem for EOM billing. |
||
Tim Brown, Garden City, NY May 18, 2011 |
||
Thanks for the test. Just updated the calc to consider the last days of the month. | ||
Carsten van Dyhr, Höör/Sweden May 29, 2018 |
||
Saved me a lot of time, thanks a lot | ||
Note: these functions are not guaranteed or supported by BrianDunning.com. Please contact the individual developer with any questions or problems.