获取指定索引处的元素。
命名空间: System.Windows.Ink
程序集: IAWinFX(在 IAWinFX.dll 中)
语法
声明
Public ReadOnly Property Item ( _
index As Integer _
) As InkRecognizer
用法
Dim instance As InkRecognizerCollection
Dim index As Integer
Dim value As InkRecognizer
value = instance.Item(index)
public InkRecognizer Item[
int index
] { get; }
public:
property InkRecognizer^ Item[int index] {
InkRecognizer^ get (int index);
}
/** @property */
public InkRecognizer get_Item(
int index
)
JScript 不支持索引属性。
参数
- index
类型:System.Int32
要获取的元素的从零开始的索引。
属性值
类型:System.Windows.Ink.InkRecognizer
指定索引处的元素。
备注
注意 在 C# 中,应按 C# 示例中所示使用该集合的索引器,而不使用该集合的 Item 属性。
示例
下面的示例获取 InkRecognizerCollection (theInkRecognizerCollection) 中的第一个识别器(如果该集合不为空)。此示例还检查该集合是否是同步的。
' Get a collection of the recognizers installed on this Tablet PC.
Dim theInkRecognizerCollection As InkRecognizerCollection = _
theInkAnalyzer.GetInkRecognizersByPriority()
' Check if there are recognizers in the collection.
If 0 < theInkRecognizerCollection.Count Then
' Get the first recognizer in the collection.
Dim theFirstInkRecognizer As InkRecognizer = theInkRecognizerCollection(0)
' Insert code here.
End If
' Check if the recognizers collection is synchronized.
If theInkRecognizerCollection.IsSynchronized Then
' Insert code here.
End If
// Create a collection of the recognizers installed on this Tablet PC.
InkRecognizerCollection theInkRecognizerCollection =
theInkAnalyzer.GetInkRecognizersByPriority();
// Check if there are recognizers in the collection.
if (0 < theInkRecognizerCollection.Count)
{
// Get the first recognizer in the collection.
InkRecognizer theFirstInkRecognizer =
theInkRecognizerCollection[0];
// Insert code here.
}
// Check if the recognizers collection is synchronized.
if (theInkRecognizerCollection.IsSynchronized)
{
// Insert code here.
}
平台
Windows Vista
.NET Framework 和 .NET Compact Framework 并不是对每个平台的所有版本都提供支持。有关支持的版本的列表,请参见.NET Framework 系统要求。
版本信息
.NET Framework
受以下版本支持:3.0