This topic has not yet been rated - Rate this topic

KeyTrigger

Expression Studio 4.0

You can use the KeyTrigger trigger in a Windows Phone project to invoke an action based on a combination of keys pressed on the keyboard (a keyboard shortcut).

To add a KeyTrigger to a Windows Phone project

  1. In the Assets panel, click Behaviors, and then drag the behavior that you want onto the object that you want to apply the behavior to. The Trigger category appears in the Properties panel.

  2. In the Trigger category, next to TriggerType (EventTrigger), click New. In the Select Object dialog box, click KeyTrigger, and then click OK.

  3. In the FiredOn drop-down list, specify either KeyDown or KeyUp:

    • KeyDown   Triggers the behavior when the keyboard shortcut is pressed.

    • KeyUp   Triggers the behavior when the keyboard shortcut is released.

To see a sample of this behavior, visit the Expression Community Gallery Ff979317.xtlink_newWindow(en-us,Expression.40).png

  Copyright © 2011 by Microsoft Corporation. All rights reserved.
Did you find this helpful?
(1500 characters remaining)
© 2013 Microsoft. All rights reserved.