Login Page - Create Account

Support Board


Date/Time: Sat, 05 Jul 2025 14:19:14 +0000



Post From: SCDateTime.AddYears fails

[2020-11-04 15:33:17]
jesslinn - Posts: 108
If one happens to add a leap year the month/day will not be the same.

Assuming that one wants one year added to Dec 1, 2003 to be Dec 1, 2004, a workaround is to use GetDateTimeYMDHMS_MS, increment the year, and use SetDateTimeYMDHMS_MS, since then the leap year logic is used.