JavaScript Date setMinutes()
JavaScript Date setMinutes()
The setMinutes() method is used for setting the minutes of a date. It can also be used to set the seconds and milliseconds.
Syntax:-
Its syntax is:- Date.setMinutes(min, sec, milliseconds)
Return:-
Its return is:- number of milliseconds of new date from 1 January, 1970
Further Explanation:-
Parameter | Description |
---|---|
min | Required. An integer represents the minutes from 0 - 59. |
sec | Optional. An integer representing the second from 0 - 50. |
milliseconds | Optional. An integer representing the milliseconds from 0 - 999. |