Hi,
I have successfully got a solution to disable future dates using javascript but how do i disable the past 7 days from todays date.
<script type="text/javascript">
function call(sender, args) {
if (sender._selectedDate > new Date()) {
alert("You cannot select a day greater than today");
sender._selectedDate = new Date();
// set the date back to the current date
sender._textbox.set_Value(sender._selectedDate.format(sender._format))
}
}
</script>
<asp:TextBox ID="txtdate" runat="server"></asp:TextBox>
<ajax:CalendarExtender ID="txtdate_CalendarExtender" runat="server"
Enabled="True" TargetControlID="txtVisitDate" OnClientDateSelectionChanged="call">
</ajax:CalendarExtender>