Share via


Ink.CreateStroke Method

Ink.CreateStroke Method

Creates a Stroke object from packet data.

Definition

Visual Basic .NET Public Function CreateStroke( _
ByVal packetData() As Integer, _
ByVal tabletPropertyDescriptionCollection As TabletPropertyDescriptionCollection _
) As Stroke
C# public Stroke CreateStroke(
int[] packetData,
TabletPropertyDescriptionCollection tabletPropertyDescriptionCollection
);
Managed C++ public: Stroke* CreateStroke(
int *packetData __gc[],
TabletPropertyDescriptionCollection *tabletPropertyDescriptionCollection
);

Parameters

packetData System.Int32[]. The array of packet data used to make up the Stroke object.
tabletPropertyDescriptionCollection Microsoft.Ink.TabletPropertyDescriptionCollection. The TabletPropertyDescriptionCollection collection that describes what properties are in the packetData array.

Return Value

Microsoft.Ink.Stroke. The newly created Stroke object.

Exceptions

ArgumentNullException Leave Site: One of the parameters is null (Nothing in Microsoft® Visual Basic® .NET).
ObjectDisposedException Leave Site: The Ink object is disposed.

Remarks

The size of the array in the packetData parameter must be divisible by the size of the tabletPropertyDescriptionCollection parameter.

Note: The first two elements of each packet in the tabletPropertyDescriptionCollection parameter must be X and then Y. If X and Y are not specified in the first and second positions, respectively, of each packet, an ArgumentException Leave Site is thrown.

Examples

See Also