Tag: Animation
Creating an Animation in XAML and Silverlight
Below is a sample code snippet that demonstrates how to create a simple animation in XAML and Silverlight Creating an Animation in XAML and Silverlight <Grid x:Name=”LayoutRoot” Background=”White”> <Canvas x:Name=”ACCanvas” xmlns=”http://schemas.microsoft.com/client/2007″ xmlns:x=”http://schemas.microsoft.com/winfx/2006/xaml” Width=”400″ Height=”300″ > <Canvas.Background> <SolidColorBrush Color=”Yellow”/> </Canvas.Background> <Rectangle Width=”190″ Height=”160″ Fill=”Red” Stroke=”Green” Canvas.Left=”0″ Canvas.Top=”50″ RenderTransformOrigin=”0,0″ > <Rectangle.RenderTransform> <TransformGroup> <RotateTransform x:Name=”RotateTransform” Angle=”0″/> <ScaleTransform x:Name=”ScaleTransform” ScaleX=”0″ ScaleY=”0″ /> </TransformGroup> </Rectangle.RenderTransform> </Rectangle> </Canvas> <Grid.Triggers> <EventTrigger RoutedEvent=”Grid.Loaded”>…