` Printed Icetips Article

Icetips Article



Par2: Stardate
2001-01-16 -- Greg Bailey
 
Use a REAL variable.

StarDate       real( 15, 8 )
CurrentDate long
CurrentTime long
    code
  StarDate = today() + clock() / 8640000


StarDate now contains both date and time in same variable.  To get
date out use the int() function or just 

    CurrentDate  = StarDate

To get the time out is a little more complicated.  

    CurrentTime = (StarDate - int( StarDate ) ) * 8640000



Printed May 10, 2024, 2:50 pm
This article has been viewed/printed 35118 times.