info.mailtraq.com > Management > Script Functions A-Z > DateTimeToReal() DateTimeToReal()Converts dates and times from Mailtraq's system formats (dd/mm/yyyy and hh:mm:ss) to real (floating point) numbers. The integer part represents the number of days since 1900 and the fraction represents the time of the day.
real := DateTimeToReal( datetime )
- real
- The floating point equivalent of datetime
- datetime
- String containing date and time in Mailtraq's system format
date_num := DateTimeToReal("20/10/1997 13:12:11");
If(date_num > 35723.5501385995,
days := date_num - DateToReal("10/10/1997")
) |