傳回 ContextNodeBaseCollection 內特定 ContextNodeBase 物件的索引。
命名空間: System.Windows.Ink.AnalysisCore
組件: IACore (在 IACore.dll 中)
語法
'宣告
Public Function IndexOf ( _
node As ContextNodeBase _
) As Integer
'用途
Dim instance As ContextNodeBaseCollection
Dim node As ContextNodeBase
Dim returnValue As Integer
returnValue = instance.IndexOf(node)
public int IndexOf(
ContextNodeBase node
)
public:
int IndexOf(
ContextNodeBase^ node
)
public int IndexOf(
ContextNodeBase node
)
public function IndexOf(
node : ContextNodeBase
) : int
參數
- node
型別:System.Windows.Ink.AnalysisCore.ContextNodeBase
搜尋 ContextNodeBase 物件。
傳回值
型別:System.Int32
ContextNodeBaseCollection 內特定 ContextNodeBase 物件的索引。
備註
如果傳入的 ContextNodeBase 物件不存在 ContextNodeBaseCollection 中,則這個方法會傳回 -1。
範例
下列範例說明如何尋找特定 ContextNodeBase (myNode) 的索引,其可能包含在 ContextNodeBaseCollection (名為 nodes) 內。
Dim index As Integer = nodes.IndexOf(myNode)
int index = nodes.IndexOf(myNode);
平台
Windows Vista, Windows XP SP2, Windows Server 2003
.NET Framework 和 .NET Compact Framework 並不支援各種平台的所有版本。如需支援平台版本的相關資訊,請參閱 .NET Framework 系統需求。
版本資訊
.NET Framework
支援版本:3.0