ASP.NET Calendar Tutorial - Synchronized month scrolling

Scroll months in first calendar. This will automatically change the months of corresponding calanders.

Start date:  
End date:  

You can implement this feature in multiple calendars using the following code.

ASPX:

<obout:Calendar runat="server" ID="StartDate" TextBoxId="sDate" OnClientMonthScrollLeft="onMonthLeft" OnClientMonthScrollRight="onMonthRight" />


Javascript:

<script type="text/javascript">

		    function onMonthRight(sender) {
		        var expression = 'EndCalendar.appendMonths()';
		        EndCalendar.addToQueue(expression);
		    }

		    function onMonthLeft(sender) {
		        var expression = 'EndCalendar.prependMonths()'
		        EndCalendar.addToQueue(expression);
		    }
        
</script>