Easy Tutorial
❮ Prop Node Nextsibling Met Loc Replace ❯

JavaScript setUTCMilliseconds() Method

JavaScript Date Object

Example

Set the milliseconds to 192 according to Universal Coordinated Time (UTC):

n Output result:


Definition and Usage

The setUTCMilliseconds() method is used to set the milliseconds of a specified time according to Universal Coordinated Time (UTC).

Note: Coordinated Universal Time (UTC), also known as Universal Coordinated Time, World Standard Time, and International Coordinated Time, is abbreviated as UTC.

Note: UTC time is the same as Greenwich Mean Time (GMT).


Browser Support

All major browsers support the setUTCMilliseconds() method.


Syntax

Parameter Values

Parameter Description
millisec Required. The value of the milliseconds field to be set for the dateObject. This is expressed in UTC. The parameter is an integer between 0 and 999: -1 is the last millisecond of the previous second<br> 1000 is the first millisecond of the next second<br> 1001 is the second millisecond of the next second

Return Value

Type Description
Number Returns the number of milliseconds between January 1, 1970, midnight and the specified time.

Technical Details

| JavaScript Version: | 1.3 | | --- | --- |


JavaScript Date Object

❮ Prop Node Nextsibling Met Loc Replace ❯