title: WPF XAML Animation How do i stop it when bound boolean becomes false?
body: <p>I want the animation to stop when the boolean CanAnimate becomes false.  It starts on true, so how do i tell it to stop when CanAnimate is false?  (The CanAnimate bool is set inside a SelectedItem setter)</p>
  
  <pre><code>&lt;Border BorderBrush="Black" BorderThickness="2" Margin="1" Name="ReviewNote"&gt;
      &lt;Border.Style&gt;
          &lt;Style TargetType="Border"&gt;
             &lt;Style.Triggers&gt;
                 &lt;DataTrigger Binding="{Binding CanAnimate}" Value="True"&gt;
                     &lt;DataTrigger.EnterActions&gt;
                         &lt;BeginStoryboard&gt;
                             &lt;Storyboard&gt;
                                &lt;DoubleAnimation 
                                      Storyboard.TargetProperty="(Border.Opacity)"
                                      From="1.0" To="0.0" AutoReverse="True" 
                                      RepeatBehavior="Forever" /&gt;
                              &lt;/Storyboard&gt;
                         &lt;/BeginStoryboard&gt;
                     &lt;/DataTrigger.EnterActions&gt;
                 &lt;/DataTrigger&gt;
              &lt;/Style.Triggers&gt;
           &lt;/Style&gt;
      &lt;/Border.Style&gt;
     &lt;TextBlock/&gt;
  &lt;/Border&gt;
  </code></pre>