Wednesday, March 24, 2010

Moving a WPF Window with a WindowStyle of None


To enable a user to move your window from any area on that window (not necessarily just the title if you want to do something really different), you simply handle the MouseLeftButtonDown event for a UIElement on your window and call the DragMove method, as shown in the following code example.

private void title_MouseLeftButtonDown(object sender, MouseButtonEventArgs e)

No comments: