Skip to main content
Version: 7.9

system.date.toMillis

This function is used in Python Scripting.

Description

Converts a Date object to its millisecond value elapsed since January 1, 1970, 00:00:00 UTC (GMT)

Client Permission Restrictions

This scripting function has no Client Permission restrictions.

Syntax

system.date.toMillis(date)

Parameters

TypeParameterDescription
DatedateThe date object to convert.

Returns

Long - An 8-byte integer representing the number of millisecond elapsed since January 1, 1970, 00:00:00 UTC (GMT)

Scope

All

Code Examples

Example #1
# This example will take the date Fri Aug 18 14:35:25 PDT 2017,
# and print out 1503092125000

date = system.date.getDate(2017, 7, 18)
datetime = system.date.setTime(date, 14, 35, 25)
print system.date.toMillis(datetime)