|
ConvertToUnixTime
int
ConvertToUnixTime(string
time )
Return
Value
Returns the integer value representing
unix time (number of seconds elapsed since January 1,
1970)
converted from given time string.Returns -1 if time string is not
properly formatted.
Parameters
time
- Time string
which is to be parsed. Must be formatted in the following
way: "1/25/2007 8:30:00"
Remarks
This function
parses a string to read an integer value.
Example
The following
example demonstrates the use of ConvertToUnixTime.
string
time =
GetTimeString("%d:%m(%B):%Y %H:%M:%S
%a")
Println(time)
Println(ConvertToUnixTime("1/15/2007
8:30:00"))
Println(FormatTime(GetTime(),
"%H:%M:%S"))
Output of the example
script:
17:01(January):2007 12:17:00 Wed
1168839000
12:17:00
|