Hi,
Situation : I have two dates, FromDate and ToDate, when I select FromDate at that time I want past dates in ToDate(past means less than that date which is selected in FromDate)be disabled.and I have my min date and max date in both the asp ajax calender extender. So can any one have that idea how to do it?
Thanks
Loading
Khargesh RajputPosted Feb 19, 2015, 11:04 PM
on textchange event of from date
{
CalendarExtenderto.StartDate=convert.todatetime(txtfromdate.text);
}
Joginder BangerPosted Feb 19, 2015, 4:06 PM
view plaincopy to clipboardprint?
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<link href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/themes/base/jquery-ui.css" rel="stylesheet" type="text/css"/> <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4/jquery.min.js">script> <script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/jquery-ui.min.js">
script>
$(document).ready(function() {
$(".datepicker").datepicker({ dateFormat: 'dd-mm-yy', buttonText: 'Select date:', firstDay: 1, buttonImageOnly: true, showOn: 'both', showAnim: 'fadeIn', minDate: '0', onSelect: function() { $(this).trigger("onchange", null); } }); });
script> head> <form id="form1" runat="server">