Set UTC Hours Method
The Set UTC Hours method sets the UTC hour of a date object to a specific hour of a 24-hour clock as a number from 0 through 23. As an option, you can also set the UTC minute, second, and millisecond.
Format
dateVar.setUTCHours(hour[, minute[, second[, millisecond]]])
The following table describes the arguments for the Set UTC Hours method.
Argument | Description |
---|---|
hour |
For more information, see Values for Dates and Times. |
minute |
|
second |
|
millisecond |
Example
For an example, see Set UTC Full Year Method.