InkPicture.Tablet 屬性
取得 InkPicture 控制項目前用來收集輸入的手寫板裝置。
命名空間: Microsoft.Ink
組件: Microsoft.Ink (在 Microsoft.Ink.dll 中)
語法
'宣告
<BrowsableAttribute(False)> _
Public ReadOnly Property Tablet As Tablet
'用途
Dim instance As InkPicture
Dim value As Tablet
value = instance.Tablet
[BrowsableAttribute(false)]
public Tablet Tablet { get; }
[BrowsableAttribute(false)]
public:
property Tablet^ Tablet {
Tablet^ get ();
}
/** @property */
/** @attribute BrowsableAttribute(false) */
public Tablet get_Tablet()
public function get Tablet () : Tablet
屬性值
型別:Microsoft.Ink.Tablet
InkPicture 控制項目前用來收集輸入的手寫板裝置。
備註
注意事項: |
---|
這個屬性只有在 InkPicture 控制項只從一個手寫板收集筆墨時才有效。如果對從所有手寫板收集筆墨的 InkPicture 存取這個屬性,則會產生例外狀況。 |
範例
這個範例會傳回一份報告,內容是關於 InkPicture 物件 (變數名稱為 mInkObject) 所參考之 Tablet 物件的屬性。
Public Function InkObjectTabletReport() As String
Dim Result As StringBuilder = New StringBuilder(512)
' Wrap access to the Tablet object in a try/catch block.
' If mInkObject is in All Tablets mode, an exception will be
' thrown when accessing the Tablet property.
Try
Result.AppendLine("The tablet associated mInkObject has the following properties:")
' accessing mInkObject.Tablet will throw an exception if in All Tablets mode
' mInkObject can be InkCollector, InkOverlay, or InkPicture
Dim mTablet As Tablet = mInkObject.Tablet
Result.AppendLine("Tablet Name: " + mTablet.Name)
Result.AppendLine("Tablet PNP ID: " + mTablet.PlugAndPlayId)
Result.AppendLine("Tablet Max Rect: " + mTablet.MaximumInputRectangle.ToString())
Result.AppendLine("Tablet Capabilities: " + mTablet.HardwareCapabilities)
Catch ex As System.Exception
Result.AppendLine("mInkObject is in all tablets mode.")
Result.AppendLine("The tablet report cannot be generated.")
End Try
Return Result.ToString()
End Function
public string InkObjectTabletReport()
{
StringBuilder Result = new StringBuilder(512);
// Wrap access to the Tablet object in a try/catch block.
// If mInkObject is in All Tablets mode, an exception will be
// thrown when accessing the Tablet property.
try
{
Result.AppendLine("The tablet associated with mInkObject has the following properties:");
// accessing mInkObject.Tablet will throw an exception if in All Tablets mode
// mInkObject can be InkCollector, InkOverlay, or InkPicture
Tablet mTablet = mInkObject.Tablet;
Result.AppendLine("Tablet Name: " + mTablet.Name);
Result.AppendLine("Tablet PNP ID: " + mTablet.PlugAndPlayId);
Result.AppendLine("Tablet Max Rect: " + mTablet.MaximumInputRectangle.ToString());
Result.AppendLine("Tablet Capabilities: " + mTablet.HardwareCapabilities);
}
catch (System.Exception)
{
Result.AppendLine("mInkObject is in all tablets mode.");
Result.AppendLine("The tablet report cannot be generated.");
}
return Result.ToString();
}
平台
Windows Vista
.NET Framework 和 .NET Compact Framework 並不支援各種平台的所有版本。如需支援平台版本的相關資訊,請參閱 .NET Framework 系統需求。
版本資訊
.NET Framework
支援版本:3.0