KNOWLEDGE BASE
Log In    |    Knowledge Base    |    4D Home
Tech Tip: Converting a LongInt time (in seconds) to a 4D Time format
PRODUCT: 4D | VERSION: 2003.4 | PLATFORM: Mac & Win
Published On: August 5, 2004

Versions: 6.8.x and 2003.x

Here is a simple way to convert a LongInt value (number of seconds) into a time format:

vTime:=Time(Time string(46800)) ` vTime:=?13:00:00?

Please note that 86400 seconds is 24 hours. If you are converting a LongInt value that is larger than 86400, Time string will continue to add hours, minutes, and seconds. For example, Time string (86401) returns 24:00:01.