Know the answer? Post it. Somebody with the same question will find it here.





The datepicker has the maxdate property that you can set when you initialize it.$("#datepicker").datepicker({ maxDate: new Date, minDate: new Date(2007, 6, 12) });Like my ans, if it helps u. Thanks :)Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend5days leftRegister
Salman BegRank #284 · 8.8K reputationPosted Jan 9, 2017, 2:31 AM EST
$(function() { $( "#datepicker" ).datepicker({ maxDate: new Date() }); });Or you can achieve this using as below:
Rajeesh MenothRank #118 · 18.4K reputationPosted Jan 9, 2017, 3:13 AM EST
Mangesh GRank #294 · 8.6K reputationPosted Jan 9, 2017, 5:30 AM EST
var maxdate = new Date();
$("[id$=txtDate]").datepicker({
maxDate: maxdate,
showOn: 'button',
buttonImageOnly: true,
buttonImage: 'http://jqueryui.com/demos/datepicker/images/calendar.gif'
});
Dinesh SanthalingamRank #2,085 · 690 reputationPosted Jan 9, 2017, 6:29 PM EST
It not works @ Mangesh Gaherwar.
Mangesh GRank #294 · 8.6K reputationPosted Jan 9, 2017, 7:52 PM EST
Dinesh SanthalingamRank #2,085 · 690 reputationPosted Jan 9, 2017, 8:29 PM EST