ComponentOne Carousel for ASP.NET Web Forms
Task-Based Help / Loading Carousel Items on Demand
In This Topic
    Loading Carousel Items on Demand
    In This Topic

    C1Carousel supports retrieving data (nodes) dynamically. Child items are loaded using AJAX when they are scrolled into view. In the examples below you'll enable loading data on demand by setting the LoadOnDemand property to True.


    In Source View

    In Source view add LoadOnDemand="True" to the <cc1:C1Carousel> tag so it appears similar to the following:

    To write code in Source View

    <cc1:C1Carousel ID="C1Carousel1" runat="server" LoadOnDemand="True">

    At Design Time

    In Design view, select the C1Carousel control and in the Properties window set the LoadOnDemand property to True.

    In Code

    Add the following code to the Page_Load event:

    To write code in Visual Basic

    Visual Basic
    Copy Code
    Me.C1Carousel1.LoadOnDemand = True
    

    To write code in C#

    C#
    Copy Code
    this.C1Carousel1.LoadOnDemand = true;