i used this code to animation my window
winLogin login = new winLogin();
login.Owner = this;
login.Show();
DoubleAnimation da = new DoubleAnimation();
da.From = 0;
da.To = this.Left + ((this.Width - login.Width) / 2);
da.AutoReverse = false;
da.Duration = new Duration(TimeSpan.FromSeconds(0.1));
login.BeginAnimation(Window.LeftProperty, da);
problem is that whenever i set the left property of this window(after the animation), it goes crazy..
i used this code to align the child windows to be always on the center bu the left property of the windows on which i used an animation cannot be properly changed.
private void Window_LocationChanged(object sender, EventArgs e) { foreach (Window win in this.OwnedWindows) { win.Top = this.Top + ((this.Height - win.Height) / 2); win.Left = this.Left + ((this.Width - win.Width) / 2); } }