InkRecognizerBaseCollection.CopyTo 方法
从特定索引处开始,将集合的元素复制到 InkRecognizerBase 数组。
命名空间: System.Windows.Ink.AnalysisCore
程序集: IACore(在 IACore.dll 中)
语法
声明
Public Sub CopyTo ( _
recognizers As InkRecognizerBase(), _
index As Integer _
)
用法
Dim instance As InkRecognizerBaseCollection
Dim recognizers As InkRecognizerBase()
Dim index As Integer
instance.CopyTo(recognizers, index)
public void CopyTo(
InkRecognizerBase[] recognizers,
int index
)
public:
void CopyTo(
array<InkRecognizerBase^>^ recognizers,
int index
)
public void CopyTo(
InkRecognizerBase[] recognizers,
int index
)
public function CopyTo(
recognizers : InkRecognizerBase[],
index : int
)
参数
- recognizers
类型:array<System.Windows.Ink.AnalysisCore.InkRecognizerBase[]
一维数组,作为从集合中复制的元素的目标。该数组必须具有从零开始的索引。
- index
类型:System.Int32
array 中从零开始的索引,将从该索引处开始复制。
备注
在下列情况下会引发异常:
array 为 null(在 Microsoft Visual Basic .NET 中为 nothing)引用。
array 是多维的。
index 小于零。
index 等于或大于 array 的长度。
集合的元素数大于从 index 到 array 末尾之间的可用空间。
示例
下面的示例将 InkRecognizerBaseCollection (theInkRecognizerCollection) 中的识别器复制到 InkRecognizerBase 数组中。
' Check if there are recognizers in the collection.
Dim theCount As Integer = theInkRecognizerCollection.Count
If (0 < theCount) Then
' Copy the recognizers in the collection to an array.
Dim theRecognizers(theCount) As InkRecognizerBase
theInkRecognizerCollection.CopyTo(theRecognizers, 0)
' Insert code here.
End If
// Check if there are recognizers in the collection.
int theCount = theInkRecognizerCollection.Count;
if (0 < theCount)
{
// Copy the recognizers in the collection to an array.
System.Windows.Ink.AnalysisCore.InkRecognizerBase[] theRecognizers =
new InkRecognizerBase[theCount];
theInkRecognizerCollection.CopyTo(theRecognizers, 0);
// Insert code here.
}
平台
Windows Vista, Windows XP SP2, Windows Server 2003
.NET Framework 和 .NET Compact Framework 并不是对每个平台的所有版本都提供支持。有关支持的版本的列表,请参见.NET Framework 系统要求。
版本信息
.NET Framework
受以下版本支持:3.0