This is a migrated thread and some comments may be shown as answers.
Rebind Rotator
1 Answer 37 Views
This is a migrated thread and some comments may be shown as answers.
Ian
Top achievements
Rank 1
Ian asked on 07 Jan 2009, 05:10 PM
Hello Telerik team,

I have a slight issue with rebinding a rotator.  I have a main aspx page with many ascx pages loaded onto it as controls, this page is a shop admin system.  On one of the ascx's there is the option to add a product to your basket, up at the top of the aspx is another ascx with a mini prieview of your basket, this ascx is on a rotator.  So as products are added to the basket the ascx at the top rotates between the products in your basket.  The problem is when you initially load the page their is nothing in your basket, when you add products nothing displays in the rotator unless you reload the page or do a postback (the page is full AJAXed up with RadAjaxPanels so there is no postbacks!)

If there is a product already in the basket (so there is something when the page initially loads), if you add a second product the rotator 'refreshes' so that now it will start rotating through all the products in the basket.  I can't work out why when you initially add to an empty basket the rotator will not refresh or rebind (i know there is no rebind option for a rotator).

I am using using ajax so that when a product is added it goes into code and does -

RadRotator1.DataSource = dt;

RadRotator1.DataBind();


with dt being a datatable of values.

If you could provide any help as to why it wouldn't be refreshing initially or how to achieve this it would be great.

Thanks in advance

Ian 

1 Answer, 1 is accepted

Sort by
0
Fiko
Telerik team
answered on 10 Jan 2009, 03:37 PM
Hi Ian,

I am not quite sure that I understand completely your scenario, but please keep in mind that the databinding on RadRotator works as standard ASP.NET databinding mechanism. That is why I suggest to implement your logic by using the standard asp:repeater control in your scenario and once you have your code working as expected the same logic will work with RadRotator.

In case if you cannot solve the problem, please, open a support ticket and attach a simple running application which demonstrates your scenario where you have implemented the desired logic with asp:repeater. We will check it and rework it for you so it uses RadRotator.


Regards,
Fiko
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
Asked by
Ian
Top achievements
Rank 1
Answers by
Fiko
Telerik team
Share this question
or