ToolStrip.GetItemAt ToolStrip.GetItemAt ToolStrip.GetItemAt ToolStrip.GetItemAt Method

定义

返回位于指定位置的项。Returns the item located at the specified location.

重载

GetItemAt(Int32, Int32) GetItemAt(Int32, Int32) GetItemAt(Int32, Int32) GetItemAt(Int32, Int32)

返回位于 ToolStrip 工作区的指定 X 坐标和 Y 坐标的项。Returns the item located at the specified x- and y-coordinates of the ToolStrip client area.

GetItemAt(Point) GetItemAt(Point) GetItemAt(Point)

返回位于 ToolStrip 的工作区中指定点的项。Returns the item located at the specified point in the client area of the ToolStrip.

GetItemAt(Int32, Int32) GetItemAt(Int32, Int32) GetItemAt(Int32, Int32) GetItemAt(Int32, Int32)

返回位于 ToolStrip 工作区的指定 X 坐标和 Y 坐标的项。Returns the item located at the specified x- and y-coordinates of the ToolStrip client area.

public:
 System::Windows::Forms::ToolStripItem ^ GetItemAt(int x, int y);
public System.Windows.Forms.ToolStripItem GetItemAt (int x, int y);
member this.GetItemAt : int * int -> System.Windows.Forms.ToolStripItem
Public Function GetItemAt (x As Integer, y As Integer) As ToolStripItem

参数

x
Int32 Int32 Int32 Int32

从工作区左边缘开始算的水平坐标,以像素为单位。The horizontal coordinate, in pixels, from the left edge of the client area.

y
Int32 Int32 Int32 Int32

从工作区上边缘开始算的垂直坐标,以像素为单位。The vertical coordinate, in pixels, from the top edge of the client area.

返回

位于指定位置的 ToolStripItem,如果找不到 ToolStripItem,则为 nullThe ToolStripItem located at the specified location, or null if the ToolStripItem is not found.

GetItemAt(Point) GetItemAt(Point) GetItemAt(Point)

返回位于 ToolStrip 的工作区中指定点的项。Returns the item located at the specified point in the client area of the ToolStrip.

public:
 System::Windows::Forms::ToolStripItem ^ GetItemAt(System::Drawing::Point point);
public System.Windows.Forms.ToolStripItem GetItemAt (System.Drawing.Point point);
member this.GetItemAt : System.Drawing.Point -> System.Windows.Forms.ToolStripItem

参数

point
Point Point Point Point

Point,在此处搜索 ToolStripItemThe Point at which to search for the ToolStripItem.

返回

指定位置处的 ToolStripItem,如果找不到 ToolStripItem,则为 nullThe ToolStripItem at the specified location, or null if the ToolStripItem is not found.

另请参阅

适用于