The setMinutes() method sets the minutes for a specified date according to local time.
dateObj.setMinutes(minutesValue[, secondsValue[, msValue]])
dateObj.setMinutes(minutesValue)
minutesValuesecondsValuesecondsValue parameter, you must also specify the minutesValue.msValuemsValue parameter, you must also specify the minutesValue and secondsValue.If you do not specify the secondsValue and msValue parameters, the values returned from getSeconds() and getMilliseconds() methods are used.
If a parameter you specify is outside of the expected range, setMinutes() attempts to update the date information in the Date object accordingly. For example, if you use 100 for secondsValue, the minutes will be incremented by 1 (minutesValue + 1), and 40 will be used for seconds.
setMinutes()var theBigDay = new Date(); theBigDay.setMinutes(45);
Created by Mozilla Contributors, license: CC-BY-SA 2.5