Jump to content

Sys2FormatTime: Difference between revisions

From EDM2
Ak120 (talk | contribs)
Ak120 (talk | contribs)
mNo edit summary
 
Line 2: Line 2:


==Arguments==
==Arguments==
1. Number of seconds (a positive integer) to be converted. (REQUIRED)
# Number of seconds (a positive integer) to be converted. (REQUIRED)<br/>This value cannot be greater than 2,147,483,647.
# Format type, one of:
#:D = return in the form 'yyyy-mm-dd hh:mm:ss (w)' where w represents the weekday (0-6 where 0=Sunday) (DEFAULT)
#:I = return in ISO8601 combined form 'yyyy-mm-ddThh:mm:ss[Z]'
#:L = return in the form 'day month year (weekday) time' where month and weekday are language-dependent abbreviations
#;Note: With D and I, time is returned in 24-hour format; L may vary.
#TZ conversion flag (indicates whether to convert to UTC from local time), one of:
#:U = return UTC or unconverted time
#:L = assume the input is in Coordinated Universal Time, and convert to local time using the current TZ (DEFAULT)


This value cannot be greater than 2,147,483,647.
==Return Value==
 
The formatted time string, or "" on error.
2. Format type, one of:
:D = return in the form 'yyyy-mm-dd hh:mm:ss (w)' where w represents the weekday (0-6 where 0=Sunday) (DEFAULT)
:I = return in ISO8601 combined form 'yyyy-mm-ddThh:mm:ss[Z]'
:L = return in the form 'day month year (weekday) time' where month and weekday are language-dependent abbreviations
 
Note: With D and I, time is returned in 24-hour format; L may vary.
 
3. TZ conversion flag (indicates whether to convert to UTC from local time), one of:
:U = return UTC or unconverted time
:L = assume the input is in Coordinated Universal Time, and convert to local time using the current TZ (DEFAULT)
 
REXX RETURN VALUE: The formatted time string, or "" on error.


[[Category:RxUtilEx]]
[[Category:RxUtilEx]]

Latest revision as of 06:21, 3 May 2020

Converts a number of seconds from the epoch (1970-01-01 0:00:00 UTC) into a formatted date and time string.

Arguments

  1. Number of seconds (a positive integer) to be converted. (REQUIRED)
    This value cannot be greater than 2,147,483,647.
  2. Format type, one of:
    D = return in the form 'yyyy-mm-dd hh:mm:ss (w)' where w represents the weekday (0-6 where 0=Sunday) (DEFAULT)
    I = return in ISO8601 combined form 'yyyy-mm-ddThh:mm:ss[Z]'
    L = return in the form 'day month year (weekday) time' where month and weekday are language-dependent abbreviations
    Note
    With D and I, time is returned in 24-hour format; L may vary.
  3. TZ conversion flag (indicates whether to convert to UTC from local time), one of:
    U = return UTC or unconverted time
    L = assume the input is in Coordinated Universal Time, and convert to local time using the current TZ (DEFAULT)

Return Value

The formatted time string, or "" on error.