Other answers so far do not address part of the WPF question. Here is my trick.
WPF does not seem to disclose detailed information about the screen, as shown in the Windows Forms Screen class mentioned in other answers.
However, you can use the WinForms screen class in your WPF program:
Add links to System.Windows.Forms and System.Drawing
var screen = System.Windows.Forms.Screen.FromRectangle( new System.Drawing.Rectangle( (int)myWindow.Left, (int)myWindow.Top, (int)myWindow.Width, (int)myWindow.Height));
Please note that if you are a nitpicker, you may have noticed that this code may have the right and bottom coordinates on one pixel in the case of converting double to int. But since you are nitpicker, you will be more than happy to fix my code :-)
Serge Wautier Aug 29 2018-11-11T00: 00Z
source share