语言

ToolStripItemCollection.IndexOf(ToolStripItem) 方法

定义

检索集合中指定项的索引。

public:
 int IndexOf(System::Windows::Forms::ToolStripItem ^ value);
public int IndexOf(System.Windows.Forms.ToolStripItem value);
member this.IndexOf : System.Windows.Forms.ToolStripItem -> int
Public Function IndexOf (value As ToolStripItem) As Integer

参数

返回

从零开始的索引值,表示在找到时ToolStripItem指定的ToolStripItemCollection位置;否则为 -1。

适用于