TIME$

TIME$

RETURNS THE CURRENT TIME

  • Type: System Variable
  • Parameter: 0
  • Group: System

ACTION

The system variable TIME$ returns the current time in a string formatted HH:MM:SS with HH for the hours, MM for the minutes and SS for the seconds.

Remark: the keyword TIME$ ends by '$' because the returned value is a string.

SYNTAX: TIME$ in an expression

USE

  • The system variable TIME$ is used to know the time.

ERROR

  • None.

EXAMPLE

print "current time "+time$

print "current hour "+str$(time_hour)

print "current minute "+str$(time_minute)

print "current second "+str$(time_second)

SEE ALSO

DATE$

DATE_YEAR

DATE_MONTH

DATE_DAY