Date Calculation - Need to add a year and minus a day - InfoPath Dev
in

InfoPath Dev

Date Calculation - Need to add a year and minus a day

Last post 07-26-2015 11:59 PM by donstephen. 1 replies.
Page 1 of 1 (2 items)
Sort Posts: Previous Next
  • 07-23-2015 06:04 PM

    Date Calculation - Need to add a year and minus a day

    I have a date picker field - based on the date selected, I need to show another date field on the same form which is basically - Add one year minus a day. AddDays does not cater for leap years. See attached screenshot of the code, works fine except if date chosen is 03/31/2015, the value calculated is 02/28/2016 - Should be 02/29/2016 as its a leap year. PLEASE HELP. THANKS a Million all INFOPATH gurus out there.
  • 07-26-2015 11:59 PM In reply to

    Re: Date Calculation - Need to add a year and minus a day

    Hi novaguy,

    Welcome to InfoPathDev.

    I have a form here which uses a simple formula to check if the year selected is a leap year or not. Please see attached form (download > right click > open in design mode) and check if you are able to add the logic to you form's formula.

    Hope this helps.

    Regards,

    Don Stephen Lambatin / Support Engineer
    Qdabra Software
Page 1 of 1 (2 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.