Rockwell-automation 1746-BAS BASIC LANGUAGE User Manual Page 126

  • Download
  • Add to my manuals
  • Print
  • Page
    / 280
  • Table of contents
  • BOOKMARKS
  • Rated. / 5. Based on customer reviews
Page view 125
Publication 1746-RM001A-US-P
10-4 Clock/Calendar Functions
CALL 43 – Retrieve Date/
Time String
Purpose
Use CALL 43 to return the current date and time as a string. PUSH the number of
the string to receive the date/time (dd-mmm-yy HH:MM:SS). You must allocate a
minimum of 18 characters for the string. This requires you to set the maximum
length for all strings to at least 18 characters.
Syntax
PUSH [string number]
CALL 43
Example
>1 REM EXAMPLE PROGRAM
>10 STRING 100,20
>20 PUSH 1: CALL 43: REM PUT DATE/TIME IN STRING 1
>30 PRINT $(1)
>40 END
READY
>RUN
16-JUN-91 13:35:00
READY
>
CALL 44 – Retrieve Date
Numeric
Purpose
Use CALL 44 to return the current date on the argument stack as three numbers.
There is no input argument to this routine and three variables are returned. The
date is POPped in day, month and year order.
Syntax
CALL 44
POP [day]
POP [month]
POP [year]
Page view 125
1 2 ... 121 122 123 124 125 126 127 128 129 130 131 ... 279 280

Comments to this Manuals

No comments