I’m experimenting with WPF animations, and I’m a bit stuck. Here’s what I need to do:
MouseOver:
Fade In (0% to 100% opacity in 2 seconds)
MouseOut:
Pause for 2 seconds
Fade Out (100% to 0% opacity in 2 seconds)
I’ve got the Fade In and Fade Out effects, but I can’t figure out how to implement the Pause, or even if it’s possible.
Here’s some XAML that shows how to do what you’re after (you can paste the entire thing into Kaxaml to try it out:
The trick is to use the
BeginTimepropertly of theDoubleAnimationclass.