ProviderConnectionPointCollection.IndexOf(ProviderConnectionPoint) 方法

定义

返回集合中特定 ProviderConnectionPoint 对象的位置。

public:
 int IndexOf(System::Web::UI::WebControls::WebParts::ProviderConnectionPoint ^ connectionPoint);
public int IndexOf (System.Web.UI.WebControls.WebParts.ProviderConnectionPoint connectionPoint);
member this.IndexOf : System.Web.UI.WebControls.WebParts.ProviderConnectionPoint -> int
Public Function IndexOf (connectionPoint As ProviderConnectionPoint) As Integer

参数

connectionPoint
ProviderConnectionPoint

要查找的 ProviderConnectionPoint

返回

一个整数,指示指定的 connectionPointProviderConnectionPointCollection 中的索引位置,索引从零开始。

注解

IndexOf 页面上有多个对象的实例 ProviderConnectionPoint ,并且代码需要知道一个连接点对象相对于集合中其他连接点对象的位置 (或索引) 时,此方法非常有用。

如果指定的提供程序连接点对象多次出现在集合中,则返回第一个匹配项的索引。

适用于

另请参阅