Mega Code Archive
Remove Animations
//File:Window.xaml.cs
using System;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Media.Animation;
namespace WpfApplication1
{
public partial class Window1 : Window
{
private AnimationClock opacityClock;
private AnimationClock widthClock;
public Window1()
{
InitializeComponent();
}
private void MyClick(object sender, RoutedEventArgs e)
{
Button button2 = sender as Button;
button2.BeginAnimation(Button.WidthProperty, null);
button2.BeginAnimation(Button.OpacityProperty, null);
}
}
}