forum

Home / DeveloperSection / Forums / WPF window reports old left property after DragMove

WPF window reports old left property after DragMove

Anonymous User 2693 19-Aug-2014

I have this issue, after calling DragMove(), the window reports its old Left property as if DragMove did not change it at all.

so lets say the window's left is currently 100 pixels, i move the window using DragMove():

private void Window_MouseDown(object sender, MouseButtonEventArgs e)

{

    if (e.LeftButton == MouseButtonState.Pressed)

    {

        DragMove();

    }

}

after which i click a button an show the new Left position of the window:

private void SomeButton_Click(object sender, RoutedEventArgs e)

{

        MessageBox.Show(Left.ToString());

}

however, the Message box still shows '100' as if the window didnt move at all although it did...

what am i missing?


wpf wpf 
Updated on 19-Aug-2014
I am a content writter !

Can you answer this question?


Answer

1 Answers

Liked By