Set Hours Method
The Set Hours method sets the hour of a date object to an hour of a 24-hour clock. You can optionally set the UTC minute, second, and millisecond. For more information, see Values for Dates and Times.
Format
dateVar.setHours(hour[, minute[, second[, millisecond]]])
The following table describes the arguments for the Set Hours method.
Argument | Description |
---|---|
hour |
For more information, see Values for Dates and Times. |
minute |
|
second |
|
millisecond |