Hi!
In this thread I read about the animation feature with the set_currentItemIndex()-Method
So I tried it. But it does not work for me. Here is what I've done to get it work:
Also it would be nice if you could show me how to turn off auto-scrolling, cannot find anything how to do this.
Thanks in advance!
Julian
In this thread I read about the animation feature with the set_currentItemIndex()-Method
So I tried it. But it does not work for me. Here is what I've done to get it work:
<
telerik:RadScriptManager
ID
=
"RadScriptManager1"
runat
=
"server"
>
</
telerik:RadScriptManager
>
<
telerik:RadRotator
ID
=
"RadRotator1"
runat
=
"server"
DataSourceID
=
"xmlDataSource1"
FrameDuration
=
"360000000"
Width
=
"675"
ItemWidth
=
"675"
Height
=
"265"
ScrollDirection
=
"Up"
ItemHeight
=
"265"
>
<
ItemTemplate
>
<
div
class
=
"itemTemplate"
>
<
img
src
=
"Images/<%# XPath("
filename") %>" style="border: 0px;" alt="banner" />
</
div
>
</
ItemTemplate
>
</
telerik:RadRotator
>
<
asp:XmlDataSource
ID
=
"xmlDataSource1"
runat
=
"server"
DataFile
=
"banners.xml"
></
asp:XmlDataSource
>
<
div
class
=
"nav"
>
<
a
href
=
"#"
onclick
=
"javascript:setNewContent(0);"
>Banner 1</
a
>
<
a
href
=
"#"
onclick
=
"javascript:setNewContent(1);"
>Banner 2</
a
>
<
a
href
=
"#"
onclick
=
"javascript:setNewContent(2);"
>Banner 3</
a
>
<
a
href
=
"#"
onclick
=
"javascript:setNewContent(3);"
>Banner 4</
a
>
<
a
href
=
"#"
onclick
=
"javascript:setNewContent(4);"
>Banner 5</
a
>
</
div
>
here the js:But doesn't work. What I have to do? //EDIT: What does not work? -> The animation does not work... the banner changes but without animationfunction setNewContent(selectedContentIndex) {
// finding the radRotator
var rotator = $find('<%= RadRotator1.ClientID %>');
rotator.set_currentItemIndex(selectedRotatorItem, true);
}
Also it would be nice if you could show me how to turn off auto-scrolling, cannot find anything how to do this.
Thanks in advance!
Julian