Screen.FromControl(Control) 方法

定义

Screen检索包含指定控件最大部分的显示。

public:
 static System::Windows::Forms::Screen ^ FromControl(System::Windows::Forms::Control ^ control);
public static System.Windows.Forms.Screen FromControl(System.Windows.Forms.Control control);
static member FromControl : System.Windows.Forms.Control -> System.Windows.Forms.Screen
Public Shared Function FromControl (control As Control) As Screen

参数

control
Control

要为其检索的 ControlA Screen

返回

一个 Screen 显示,其中包含指定控件的最大区域。 在没有显示控件的多个显示环境中,将返回离指定控件最近的显示。

适用于