New to Telerik UI for ASP.NET AJAX? Download free 30-day trial


The OnClientDrag client-side event occurs when the user moves the mouse while dragging a RadDock control.

The event handler receives a single parameter: the instance of the RadDock control that is being dragged.

The following example uses the OnClientDrag event handler to update a label during a drag operation:

<script type="text/javascript">
    function Drag(dock)
        var label = document.getElementById("<%= Label1.ClientID %>");
        var now = new Date();
        var timeStr = now.getHours() + ":" + now.getMinutes() + ":" + now.getSeconds() + "." + now.getMilliseconds();
        label.innerHTML = dock.get_uniqueID() + ": " + timeStr;
<telerik:RadDockLayout ID="RadDockLayout1" runat="server">
 <telerik:RadDockZone ID="RadDockZone1" runat="server">
     OnClientDrag="Drag" />   
<asp:Label ID="Label1" runat="server" Text="Drag Info"></asp:Label>

See Also

In this article