Winform编程时屏幕宽度和高度的调用

winform下的

(System.Windows.Forms.)Screen.PrimaryScreen.Bounds.Width                        (System.Windows.Forms.)Screen.PrimaryScreen.Bounds.Height

括号中的可以省去不写


WPF下的:

double   h   =   SystemParameters.PrimaryScreenHeight; 
double   w   =   SystemParameters.PrimaryScreenWidth;

原文地址:https://www.cnblogs.com/lcxu2/p/2003999.html