StylusButton.StylusButtonState Property

 

Gets the state of the stylus button.

Namespace:   System.Windows.Input
Assembly:  PresentationCore (in PresentationCore.dll)

public StylusButtonState StylusButtonState { get; }

Property Value

Type: System.Windows.Input.StylusButtonState

One of the StylusButtonState values.

The following example demonstrates the StylusButtonState property.

// Get the state of the StylusButton
switch (myStylusButton.StylusButtonState)
{
    case StylusButtonState.Down:
        textbox1.AppendText("StylusButton.State: Down\n");
        break;

    default:  // StylusButtonState.Up
        textbox1.AppendText("StylusButton.State: Up\n");
        break;
}

.NET Framework
Available since 3.0
Return to top
Show: