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

返回

Int32

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

注解

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

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

适用于

另请参阅