I have a WPF application and I need to know how to center the wain window programatically (not in XAML).
I need to be able to do this both at startup and in response
In the window element just add this attribute-value pair: WindowStartupLocation="CenterScreen"