Tech
Forums
Jobs
Books
Events
Interviews
Live
More
Learn
Training
Career
Members
Videos
News
Blogs
Login
Sign Up
Ask Question
1
Reply
how to set minimum date in datetimepicker using jquery...?
Aarif khan
Jun 14 2016 8:52 AM
352
Reply
the code i have tired is
@Html.EditorFor(model => model.taxDefination.EffectiveDate, "", new { htmlAttributes = new { @class = "form-control datePickerOnly", @id = "txteffectivefrom", @required = "required", @style = "z-index:99999;", @Value = Model.taxDefination.EffectiveDate.ToString("dd/MM/yyyy") } })
var today = new Date();
var dd = today.getDate() - 7;
var mm = today.getMonth() + 1; //January is 0!
var yyyy = today.getFullYear();
if (dd < 10)
{
dd = '0' + dd
}
if (mm < 10)
{
mm = '0' + mm
}
var today = dd + '-' + mm + '-' + yyyy;
$("#txteffectivefrom").datePickerOnly("option", "minDate", today);
it is not working
Upload Source Code
Select only zip and rar file.
Post
Reset
Cancel
Answers (
1
)
Next Recommended Forum
Unable to start debugging on the web server.
Connection String