Home / Community & Support / Knowledge Base / RadControls for ASP.NET and ASP.NET AJAX / Scheduler / Hide the popup calendar in RadScheduler by clicking outside of it.

Hide the popup calendar in RadScheduler by clicking outside of it.

Article Info

Rating: 5

Article information

Article relates to

 RadScheduler    

Created by

 Peter, Telerik

Last modified

 May 29, 2009

Last modified by

 Peter, Telerik


HOW TO

Hide the popup calendar in RadScheduler by clicking outside of it.

DESCRIPTION

Jquery and general javascript is used to achieve this.
hide popup calendar

SOLUTION

<script type="text/javascript">  
        window.$ = $telerik.$  
        var scheduler = null;         
        function pageLoad()   
        {  
            scheduler = $find('<%= RadScheduler1.ClientID %>');  
        }  
        $(document).click(function(event) {  
            var target = event.target || event.srcElement;  
             
            if (!$(target).parents().is(".RadCalendar") & !$(target).is(".rsDatePickerActivator"))   
            {  
                if (scheduler._datePickerCalendarExpanded)  
                    scheduler._onDatePickerToggle();  
            }  
        });  
    </script> 

Comments

If you'd like to comment on this KB article, please, send us a Support Ticket.
Thank you!

Please Sign In to rate this article.