getTime (Date.getTime method)

public getTime() : Number

Returns the number of milliseconds since midnight January 1, 1970, universal time, for the specified Date object. Use this method to represent a specific instant in time when comparing two or more Date objects.

Availability

Flash Lite 2.0

Returns

Number - An integer.

Example

The following example uses the constructor to create a Date object based on the current time, and uses the getTime() method to return the number of milliseconds since midnight January 1, 1970:

var my_date:Date = new Date(); 
trace(my_date.getTime());