How to format minDate for datepicker
Hello,
How do I format the minDate that goes to the datepicker.
Im getting a month and year from a previous ?datepicked? field.
And Im using the value in that field to set up a minDate thingy.
I have the below, but I cant seem to get the format correct.
SCAYEA is a 2013 field.
- $("#SCDATE").click(function () {
- var mm = $("#SCAPER").val();
- var yy = $("#SCAYEA").val();
- var yymmdd = yy + '/' + mm + '/01';
- var mmddyy = mm + '/01/' + yy;
- $("#SCDATE").datepicker({minDate:yymmdd});
- });