Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Strange result from Month calculation

Featured Replies

  • Newbies

We were trying to use Month() calculation to set reminder. However, it is not returning the result as intended.

We have a startDate field and would like to add exact 2 months to startDate as reminder. Intended results are:

startDate > reminderDate

19/03/2011 > 18/05/2011

01/11/2011 > 31/12/2012

30/11/2011 > 29/01/2012

31/12/2011 > 29/02/2012

01/01/2012 > 29/02/2012

In remWe used Date(Month(startDate)+2; Day(startDate); Year(startDate))-1

Solved by comment

Go to solution
  • Solution

Try =

 

Let ( [
newDate = Date ( Month ( StartDate ) + 2 ; Day ( StartDate ) ; Year ( StartDate ) ) - 1  ;
limit = Date ( Month ( StartDate ) + 3 ; 0 ; Year ( StartDate ) )
] ;
Min ( newDate ; limit )
)
  • Author
  • Newbies

Hi,

 

Sorry, I used my tiny iphone to compose this message and accidentally pressed on the Post button before I could finish my message.

 

Thanks god that you understand my question and it has been resolved.

 

Many thanks.

Create an account or sign in to comment

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.