Skip to main content
Version: v6.5.0

Convert-to-Unix-Timestamp

Command Description​

Converts a time data (obtained by the get time command) to a Unix timestamp

Command Prototype​

iRet = Time.ToUnixTime(dTime, bMS)

Parameter Description​

ParameterRequiredTypeDefaultDescription
dTimeTrueexpressiondTimeThe time data to be converted, the default is the current time
bMSTruebooleanNoneWhether to convert to a timestamp of millisecond precision; the default is false

return​

iRet,The variable used to save the output of the command.

Demo​

Dim iRet 
iRet = Time.ToUnixTime(44601.642673611, false)
TracePrint(iRet)
/**
iRet = 1644391526
*/