title: Windows Phone 7 Control Animation Using C#
body: <p>I have created several animations (storyboards) on different pages using Expression Blend.</p>
  
  <p>One case i am running in is the login page where if the user fails to enter the correct password a messagebox will show statng incorrect password, however the animation will play eventhough the password was incorrect. This is happening because in expression blend i have added a behavior on the button upon being clicked to play the animations, so how can i apply conditions also to that button?</p>
  
  <p>My question is how can i from my c# code using if statements to prevent the playback of the animation if the password entered is incorrect?</p>
  
  <p>Everything is working fine except the animation part where i just want to be able to control it from my c# code.</p>