Tablet.DeviceKind Property
Gets the TabletDeviceKind value that indicates the type of the tablet device.
Namespace: Microsoft.Ink
Assembly: Microsoft.Ink (in Microsoft.Ink.dll)
Syntax
'Declaration
Public ReadOnly Property DeviceKind As TabletDeviceKind
'Usage
Dim instance As Tablet
Dim value As TabletDeviceKind
value = instance.DeviceKind
public TabletDeviceKind DeviceKind { get; }
public:
property TabletDeviceKind DeviceKind {
TabletDeviceKind get ();
}
public function get DeviceKind () : TabletDeviceKind
Property Value
Type: Microsoft.Ink.TabletDeviceKind
The TabletDeviceKind value that indicates the type of the tablet device.
Remarks
This property is new to the Microsoft.Ink version 6.0 assembly.
Examples
In this example, the Button object btOpenFile is made to be a different size, depending upon the type of tablet device that is being used.
Private Sub AdjustInterface(ByVal theTablet As Tablet)
Select Case theTablet.DeviceKind
Case TabletDeviceKind.Mouse
btOpenFile.Size = New Size(24, 24)
Case TabletDeviceKind.Pen
btOpenFile.Size = New Size(32, 32)
Case TabletDeviceKind.Touch
btOpenFile.Size = New Size(48, 48)
End Select
End Sub
private void AdjustInterface(Tablet theTablet)
{
switch (theTablet.DeviceKind)
{
case TabletDeviceKind.Mouse:
btOpenFile.Size = new Size(24, 24);
break;
case TabletDeviceKind.Pen:
btOpenFile.Size = new Size(32, 32);
break;
case TabletDeviceKind.Touch:
btOpenFile.Size = new Size(48, 48);
break;
}
}
Platforms
Windows 7, Windows Vista, Windows Server 2008 R2, Windows Server 2008
The .NET Framework and .NET Compact Framework do not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.
Version Information
.NET Framework
Supported in: 3.0