Mega Code Archive

 
Categories / VB.Net Tutorial / WPF
 

Animating nested properties

<Page xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"       xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"       HorizontalAlignment="Stretch" VerticalAlignment="Stretch">     <Ellipse Fill="Red" Height="100" Width="200">       <Ellipse.Triggers>         <EventTrigger RoutedEvent="Ellipse.Loaded">           <BeginStoryboard>             <Storyboard>               <ColorAnimation                  Storyboard.TargetProperty="(Ellipse.Fill).(SolidColorBrush.Color)"                  Duration="0:0:7" From="Red" To="Purple"                  RepeatBehavior="Forever" AutoReverse="True" />             </Storyboard>           </BeginStoryboard>         </EventTrigger>       </Ellipse.Triggers>     </Ellipse>      </Page>