Animation or Transition?

2 posts, 0 answers
  1. Dele
    Dele avatar
    23 posts
    Member since:
    Jun 2012

    Posted 23 Nov 2010 Link to this post


    I have a quick question on a simple scenario I would like to accomplish.

    I would like to show/hide a certain section of my panorama item when i click on a button.  And I would also like to add some sort of animation/transition.

    What would be the right control to use?  The Animation or Transition?  My first guess was the Animation.  if so, is there a simple way to do this?  The code examples you have aren't quite clear.

  2. Valentin.Stoychev
    Valentin.Stoychev avatar
    2198 posts

    Posted 24 Nov 2010 Link to this post

    Hello Dele,

    A general rule of thumb is to use transition when swapping one content with another. You can use the RadTransitionControl for this purpose - it will animate the transition between the old and the new content.

    In order to change a specific property of an element with animation, you should use the RadAnimation framework. In this case - you can use the RadFadeAnimation to animate the Opacity property of the element and when the animation is done to set the Visibility of your element to Collapsed.

    The other option will be if you use the RadResizeAnimation to animate the Width/Height properties of your element.

    Hope this makes it more clear. Please let us know if you need more help.

    All the best,
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
  3. DevCraft banner
Back to Top