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

Rotator and WrapFrames with Buttons

3 Answers 38 Views
Rotator
This is a migrated thread and some comments may be shown as answers.
Nicolas Fahr
Top achievements
Rank 1
Nicolas Fahr asked on 15 Aug 2012, 10:22 AM
Consider the example on http://demos.telerik.com/aspnet-ajax/rotator/examples/default/defaultcs.aspx and change the RotatorType to Buttons and the Width to 1000px.
Is there any solution how to have a smoother moving when clicking on the rotator buttons?

When WrapFrames is disabled, the rotation seems to look good, but we indeed need the WrapFrames functionality set to true.

Thanks in advance

3 Answers, 1 is accepted

Sort by
0
Slav
Telerik team
answered on 20 Aug 2012, 08:33 AM
Hello Nicolas,

In order for the RadRotator to work correctly in all scenarios please ensure that there are enough items for sliding the control more than one time (not all of them should be visible when the page is loaded) and the number of rotator items fits the width of the ViewPort, for example if there is space for 5 items, populate the control with 10, 15 etc. In the case you described all RadRotator items are visible in the ViewPort and they are reloaded when the control button is clicked. To avoid this effect you can add 10 more items in the RadRotator to ensure that they are enough items to be displayed in the ViewPort after the slide.

Another approach is to utilize the ButtonsOver rotator mode or the Client-side API of the RadRotator (the showNext method) in order to slide only one item instead of all that are currently visible.

I hope this helps. Feel free to contact us again if you run into more difficulties.

Kind regards,
Slav
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
0
Nicolas Fahr
Top achievements
Rank 1
answered on 20 Aug 2012, 09:55 PM
Hello Slav,

thank you for the response.
I understand this is the expected behaviour,
What I would have expected is: If 5 items are displayed in the viewport and there are 6 items in the databound collection, there should be items # 6, 1, 2, 3 and 4 on the second page; Items # 5, 1, 2, 3 and 4 on the next page and so on...
Maybe you have an approach for that?

Nicolas
0
Slav
Telerik team
answered on 23 Aug 2012, 11:21 AM
Hello Nicolas,

You can achieve the desired effect if you double the data, entered in the RadRotator. For example, if you have six items, you will add them again so that every item is repeated. This way there will be enough items to display on every page of the rotator. Note that this will be required only when number of items is less than the doubled number of items that fit on one page, in this case the scrolling will be performed without clearing the already displayed items.

Greetings,
Slav
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
Tags
Rotator
Asked by
Nicolas Fahr
Top achievements
Rank 1
Answers by
Slav
Telerik team
Nicolas Fahr
Top achievements
Rank 1
Share this question
or