New to Telerik UI for ASP.NET AJAXStart a free 30-day trial

Events Overview

RadAjaxLoadingPanel contains the following client events:

NameDescription
OnClientShowingFired before the loading panel is shown.
OnClientHidingFired before the loading panel hides.

To use these events, simply write a JavaScript function that can be called when the event occurs(Example 2 ).You then assign the name of the JavaScript function as the value of the the corresponding property.

Example 2: Cancel the default behavior when shows and hides the RadAjaxLoadingPanel and apply a custom behavior for both actions.

ASP.NET
<script type="text/javascript">
	function MyClientShowing(sender, eventArgs) {
	    eventArgs.get_loadingElement().style.border = "2px solid red";
	    eventArgs.set_cancelNativeDisplay(true);
	     $telerik.$(eventArgs.get_loadingElement()).show("slow");
	}
	function MyClientHiding(sender, eventArgs) {
	    eventArgs.get_loadingElement().style.border = "2px solid blue";
	    eventArgs.set_cancelNativeDisplay(true);
	    $telerik.$(eventArgs.get_loadingElement()).hide("slow");
	}
</script>
<telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel1" runat="server" BackColor="yellow"
	OnClientShowing="MyClientShowing" OnClientHiding="MyClientHiding" />

See Also

In this article
See Also
Not finding the help you need?
Contact Support