This is a migrated thread and some comments may be shown as answers.

Ajax - Rotator : Why display jpeg is not the first one?

2 Answers 52 Views
Rotator
This is a migrated thread and some comments may be shown as answers.
edward
Top achievements
Rank 1
edward asked on 21 Apr 2010, 08:52 AM

Ajax - Rotator : Why display jpeg is not the first one?

I have 16 jpeg files for display
Each time show one jpeg only.

I use the sqldatasource to testing the result is correct .
Also I add the get item to display the counter of the item

The result
---------------------
The start screen
jpeg (this is the no.15 jpeg)

1/16
--------------------
press the forward button
jpeg (this is the no.16 jpeg)

16/16
-------------------
press the forward button  
jpeg (this is the no.1 jpeg)

1/16
---------------------

Question:
1)  Why the rotator first display is the no.15 jpeg not the first one jpeg.
2)  When I try using WrapFrames="false" , the last jpeg is blank.

source:
-----------------------------
 <span class="title"><telerik:RadRotator ID="RadRotatorHorizontal"
                runat="server" DataSourceID="SqlDataSource1"
     RotatorType="FromCode" Height="480px"

Width="1471px" ItemHeight="480px" ItemWidth="1200px" scrollduration="1" frameduration="2000"
      ScrollDirection="Right"

CssClass="floatRotator" OnClientItemShown="OnClientItemShown" >
     <ItemTemplate>
      <div class="itemTemplate">
                            <asp:Image runat="server" ID="Image"
                                ImageUrl='<%# Eval("ImageURL_Full_FileName") %>' 
                                CssClass="displayimage" AlternateText="Customer Image" Height="455px"
                                Width="1200px"/>
          <br />

 

<asp:sqldatasource id="SqlDataSource1" runat="server" connectionstring="<%$

ConnectionStrings:ConnectionString9 %>"
  
        selectcommand="SELECT * FROM [Cam_Recording] ORDER BY [ImageURL_Full_FileName]"
        ProviderName="<%$ ConnectionStrings:ConnectionString9.ProviderName %>">
</asp:sqldatasource>

 

               function OnClientItemShown(sender, args) {
         var textitem = (args.get_item().get_index() + 1) + "/" + (sender.get_items().length);
         var Label5value = document.getElementById("Label5");
                Label5value.innerHTML = textitem;
     }

-----------------------------

Thanks!!!

2 Answers, 1 is accepted

Sort by
0
Fiko
Telerik team
answered on 23 Apr 2010, 01:31 PM
Hi Edward,

In reference to your questions:
  1. The reason for the first issue was a problem in the RadRotator's client-side code, but we have already fixed it and the changes will be available in the next internal build.
  2. This problem occurs in situations when the Width, ItemWidth, Height and ItemHeight are not correctly set. In your case you need to set the Rotator's ItemWidth property to be equal to the Width property of the image. More details about the RadRotator's configuration can be found in this KB article.

I hope this helps.

Kind regards,
Fiko
the Telerik team

Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
0
edward
Top achievements
Rank 1
answered on 25 Apr 2010, 05:18 PM
Dear Fiko,

thanks for reply!

The reason for the first issue was a problem in the RadRotator's client-side code, but we have already fixed it and the changes will be available in the next internal build.

     --- what is the time of the next internal build

This problem occurs in situations when the Width, ItemWidth, Height and ItemHeight are not correctly set. In your case you need to set the Rotator's ItemWidth property to be equal to the Width property of the image. More details about the RadRotator's configuration can be found in this KB article.


    --- I have set the same width or you can testing the sample in my ticket, tks!

Best Regards

Edward

Tags
Rotator
Asked by
edward
Top achievements
Rank 1
Answers by
Fiko
Telerik team
edward
Top achievements
Rank 1
Share this question
or