StylusPoint.GetPropertyValue(StylusPointProperty) 方法

定義

回傳指定屬性的值。

public:
 int GetPropertyValue(System::Windows::Input::StylusPointProperty ^ stylusPointProperty);
public int GetPropertyValue(System.Windows.Input.StylusPointProperty stylusPointProperty);
member this.GetPropertyValue : System.Windows.Input.StylusPointProperty -> int
Public Function GetPropertyValue (stylusPointProperty As StylusPointProperty) As Integer

參數

stylusPointProperty
StylusPointProperty

StylusPointProperty 就是要取得哪個房產價值。

傳回

指定 StylusPointProperty的值。

例外狀況

stylusPointProperty 不是 中的 Description性質之一。

範例

以下範例在取得該屬性值前,檢查是否存在觸控筆點屬性。 此範例假設存在一個 StylusPoint 被呼喚 point的 。

if (point.HasProperty(StylusPointProperties.PitchRotation))
{
    int pitchRotation = point.GetPropertyValue(StylusPointProperties.PitchRotation);
}
If point.HasProperty(StylusPointProperties.PitchRotation) Then
    Dim pitchRotation As Integer = _
            point.GetPropertyValue(StylusPointProperties.PitchRotation)
End If

備註

要檢查 是否 StylusPoint 包含指定屬性,請先呼叫 , HasProperty 再呼叫 方法 GetPropertyValue 或 方法 SetPropertyValue

適用於