Auto scroll or programmatically scroll

4 posts, 0 answers
  1. E
    E avatar
    7 posts
    Member since:
    Jun 2008

    Posted 04 Jul 2008 Link to this post

    Is there any way to automatically scroll items?  I see the AutoScroll property but when I set it to true it doesn't seem to do anything.

  2. Mike
    Mike avatar
    640 posts

    Posted 07 Jul 2008 Link to this post


    I hope I got you right and your question is whether RadCarousel can automatically loop its items. If so, the answer is that this feature will be available in a couple of weeks, in the Q2 release.
    You can have similar behavior for the current version by using a workaround. Change the SelectedIndex of carousel items container, using a Timer. I've attached a sample project that demonstrates the approach.

    All the best,
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
  3. DevCraft R3 2016 release webinar banner
  4. Richard Thurgood
    Richard Thurgood avatar
    26 posts
    Member since:
    Nov 2007

    Posted 10 Jul 2008 Link to this post

    This sample is great - but I was wondering if you could modify it to show me how I can add elements dynamically.  More specifically, I'd like to add RadPanels. 

    Here's what I'd like:
    - Create a form
    - Add 4 RadPanels to the form
    - Change the color of each panel (so I can see them clearly)
    - Add a RadCarousel to the form

    In the code behind:
    - Create a method called PopulateCarousel() to add RadPanels to the RadCarousel.
    - Call this method in the Form_Load event.
    - Create a method called DisplaySelectedPanel() that will stretch the selected panel to full size in the form. This method would be called when this item is clicked in the RadCarousel.

    I tried to do this based on the samples and using your sample but couldn't get it to work. I'm sure your sample app can be modified to do this, right?

  5. Mike
    Mike avatar
    640 posts

    Posted 14 Jul 2008 Link to this post

    Hello Richard,

    A panel-based carousel scenario would be much more difficult to implement. The main problem is that RadCarousel is optimized to work with graphical elements and images, rendered by the TPF only. Unfortunately, this does not cover the case of rendering nested Windows Forms controls. Even though you can use RadHostItems to bridge several controls in TPF, an important drawback of this approach would be the inconsistently synchronized painting and scaling problems. 
    That's why I would suggest the following: instead of rotating panels in RadCarousel, you can rotate only snapshot images of these panels. The approach is relatively simple and does not require extensive coding. I've prepared another sample application that can guide you in this case. Here is a screenshots of the design time view of the carousel and panels:

    Runtime, when you click on a panel image in the carousel it would pop up like this:

    Kind regards,
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
Back to Top