Rotator - Live XML

Data streamed live from http://feeds.feedburner.com/Telerik
  • 08:19
    Fri, Nov 16, 2018
    Designing Digital Products for the Lizard Brain
  • 04:10
    Thu, Nov 15, 2018
    Avoiding Digital Product Shipwreck: The UX Iceberg
  • 12:40
    Thu, Nov 15, 2018
    Learn How to Use Vuex by Building an Online Shopping Website
  • 04:59
    Wed, Nov 14, 2018
    Why Choose the Telerik WPF DataGrid for Your Next Project
  • 03:50
    Wed, Nov 14, 2018
    All You Could Ever Want to Know about the Kendo UI Button
  • 09:42
    Tue, Nov 13, 2018
    Machine Learning With ML.NET
  • 05:42
    Tue, Nov 13, 2018
    Offline-First Vue Apps with Hoodie & Workbox
  • 07:46
    Mon, Nov 12, 2018
    How to Create a Booking Form for Your Web App
  • 05:35
    Mon, Nov 12, 2018
    Getting Started with Angular & Kendo UI
  • 09:15
    Fri, Nov 9, 2018
    User Testing Made Me a Better Designer
  • 05:23
    Fri, Nov 9, 2018
    Troubleshooting an ASP.NET Core App Running in Docker
  • 08:35
    Thu, Nov 8, 2018
    Announcing the Report Server API v2 and .NET Client
  • 03:47
    Thu, Nov 8, 2018
    One Fiddler to Rule Them All
  • 10:30
    Wed, Nov 7, 2018
    New AutoCompleteView for Xamarin.Forms
  • 09:12
    Tue, Nov 6, 2018
    DevReach for .NET Developers
    
Isolate this demo as a stand-alone application
  • About this demo
  • C#
  • VB

RadRotator has support for live XML feeds.

You can make use of this feature very easily - all you need to do is use a XmlDataSource source and set it to the URL of the live feed. Finally, you might need to set the XmlDataSource's XPath span.__group0.This way you could easily deliver public news to your site using your own formatting and styling.
  • DefaultCS.aspx
  • DefaultCS.aspx.cs
  • styles.css
<%@ Page AutoEventWireup="true" Inherits="Telerik.Web.Examples.Rotator.Functionality.LiveXML.DefaultCS"CodeFile="DefaultCS.aspx.cs" Language="C#"  %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<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" />
</head>
<body>
    <form id="form1" runat="server">
    <telerik:RadScriptManager runat="server" ID="RadScriptManager1" />
    <telerik:RadSkinManager ID="RadSkinManager1" runat="server" ShowChooser="true" />
    <div class="demo-container no-bg">
        <div class="backElement">
            <div class="titleText">
                Data streamed live from <a href="http://feeds.feedburner.com/Telerik">http://feeds.feedburner.com/Telerik</a><br />
            </div>
            <telerik:RadRotator RenderMode="Lightweight" ID="RadRotator1" Skin="Silk" RotatorType="AutomaticAdvance" ScrollDirection="Up"
                ScrollDuration="2000" runat="server" Width="493"
                ItemWidth="493" Height="192" ItemHeight="64" FrameDuration="1" InitialItemIndex="-1"
                CssClass="rotator">
                <ItemTemplate>
                    <div class="itemTemplate" style="background-image: url('images/<%# this.GetDayOfWeek(XPath("be:published", NamespaceManager).ToString()) %>.png');">
                        <div class="dateTime">
                            <div class="time">
                                <%# (this.GetTimeOnly(XPath("be:published", NamespaceManager).ToString())) %>
                            </div>
                            <div class="date">
                                <%# (this.GetDateOnly(XPath("be:published", NamespaceManager).ToString()))%>
                            </div>
                        </div>
                        <div class="title">
                            <span>
                                <%# System.Web.HttpUtility.HtmlEncode(XPath("be:title", NamespaceManager).ToString())%>
                            </span>
                        </div>
                    </div>
                </ItemTemplate>
            </telerik:RadRotator>
            <asp:Label ID="lblMessage" Visible="false" CssClass="message" runat="server" />
        </div>
    </div>
    </form>
</body>
</html>

Find Assistance

Help Us Improve

Was this example helpful?