Input Month stepDown() Method
Example
Decrement the value of a month field by 3 months:
document.getElementById("myMonth").stepDown(3);
Try it Yourself »
Definition and Usage
The stepDown() method decrements the value of the month field by a specified number.
This method will only have an affect on MONTHS (not years).
Tip: To increment the value, use the stepUp() method.
Browser Support
Method | |||||
---|---|---|---|---|---|
stepDown() | Yes | 12.0 | Not supported | Yes | Yes |
Syntax
numberObject.stepDown(number)
Parameter Values
Parameter | Description |
---|---|
number | Required. Specifies the amount of months the month field should
decrease. If omitted, the months are decremented by "1" |
Technical Details
Return Value: | No return value |
---|
More Examples
Example
Decrement the value of a month field by 1 (default):
document.getElementById("myMonth").stepDown();
Try it Yourself »
Input Month Object