0

:) hi everybody,

im newer in asp.net. today, im trying to bind my data to the Nivo Slider by the Data List. The code is like this:

<div class="slideshow">
            <div id="slider" class="nivoSlider">
                <asp:SqlDataSource ID="SqlDataSource1" runat="server" 
                    ConnectionString="<%$ ConnectionStrings:ConnectionString %>" 
                    SelectCommand="SELECT * FROM [SLIDEIMAGE]"></asp:SqlDataSource>
                <asp:DataList ID="DataList1" runat="server" DataSourceID="SqlDataSource1">
                <ItemStyle />
                <ItemTemplate>
                <img src="<%# Eval("IMAGENAME", "images/slide/{0}") %>" width="971" height="233" title="<%# Eval("IMAGEDESCRIPTION") %>" alt="<%# Eval("IMAGEID") %>" />
                </ItemTemplate>
                </asp:DataList>
</div>
            <script type="text/javascript" src="Scripts/jquery.nivo.slider.js"></script>
            <script type="text/javascript">
                $(window).load(function () {
                    $('#slider').nivoSlider();
                });
            </script>
        </div>

But the problem is Nivo slider can only load the first record in my database and show it into slider. even though in my db has a lot of records... so i want to know that can i have any way else to bind my data to the Nivo Slider which make the Nivo Slider can load all the records from db?

Thanks a lot :) - please help me in this problem !

3
Contributors
5
Replies
8
Views
6 Years
Discussion Span
Last Post by shanky007
0

i already test :) it work normaly. just only when i bind my data to Nivo, the problem appear.. :)

0

finally i solved it. so i wanna tell you guys to know 2.
i change the Datalist to use Repeater Control and it is working now. :)) :x

This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.