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

Client-side Events

  • Friday, July 18, 2008
    TELERIK BLOGS: RadRotator binding to XML data
  • Wednesday, July 16, 2008
    TELERIK BLOGS: Telerik TV Launches Episode 3
  • Wednesday, July 16, 2008
    TELERIK BLOGS: Accessibility and RadEditor
    
Event log

RadRotator offers a number of client events that developers can use.

  • OnClientLoad - raised after the control is initialized
  • OnClientItemClicking - raised when an item is clicked, immediately after the mouse button is released. The event can be canceled.
  • OnClientItemClicked - raised after an item is clicked
  • OnClientMouseOver - raised when the mouse hovers over an item
  • OnClientMouseOut - raised after the mouse leaves an item
  • OnClientItemShowing - raised when an item is about to be shown
  • OnClientItemShown - raised after an item has been shown

There are three more client events that are related to the Load On Demand functionlity:

  • OnClientItemsRequesting - raised before the items of the control are loaded on demand
  • OnClientItemsRequested - raised when the items of the control are successfully loaded on demand
  • OnClientItemsRequestFailed - raised when the request for loading items on demand fails.

You can check the online demo Load On Demand for more information and demonstration of these client events.

  • DefaultVB.aspx
  • scripts.js
  • styles.css
  • news.xml
<%@ Page Language="vb" AutoEventWireup="true"  %>

<%@ Register TagPrefix="telerik" Namespace="Telerik.Web.UI" Assembly="Telerik.Web.UI" %>
<!DOCTYPE html>
<html xmlns='http://www.w3.org/1999/xhtml'>
<head runat="server">
    <title>Telerik ASP.NET Example</title>
    <link href="styles.css" rel="stylesheet" type="text/css" />
    <script type="text/javascript" src="scripts.js"></script>
</head>
<body>
    <form id="form1" runat="server">
    <telerik:RadScriptManager runat="server" ID="RadScriptManager1" />
    <telerik:RadSkinManager ID="RadSkinManager1" runat="server" ShowChooser="true" />
    <div class="demo-containers">
        <div class="demo-container">
            <telerik:RadRotator RenderMode="Lightweight" ID="RadRotator1" runat="server" OnClientItemShowing="itemShowing_handler"
                OnClientItemShown="itemShown_handler" OnClientItemClicking="itemClicking_handler"
                OnClientItemClicked="itemClicked_handler" OnClientMouseOver="mouseOver_handler"
                OnClientMouseOut="mouseOut_handler" DataSourceID="xmlDataSource1" Height="60px"
                ItemHeight="60px" Width="320px" ItemWidth="320px" Style="float: left;">
                <ItemTemplate>
                    <div class="itemTemplate">
                        <%# XPath("Date")%>
                        <br />
                        <%# XPath("Title")%>
                    </div>
                </ItemTemplate>
            </telerik:RadRotator>
        </div>
    </div>
    <asp:XmlDataSource ID="xmlDataSource1" runat="server" DataFile="news.xml"></asp:XmlDataSource>
    <qsf:EventLogConsole runat="server" ID="RotatorEventLog" AllowClear="true"></qsf:EventLogConsole>
    </form>
</body>
</html>

Support & Learning Resources

Find Assistance