# Key Press Trigger

> `UiPath.Core.Activities.KeyPressTriggerV2`

`UiPath.Core.Activities.KeyPressTriggerV2`

## Description

Monitors keyboard events on a specified UI element.

It can be used either within a triggered
workflow or within a [Trigger Scope](https://docs.uipath.com/activities/other/latest/user-guide/trigger-scope) activity.

## Properties

### **Common**

* **DisplayName** - The display name of the activity.

### **Input**

* **Key** - The key that is monitored. Special keys are supported and you can select them from the activity drop-down list. This field
  supports only strings and String variables.
* **Selector** - Text property used to find a particular UI element when the activity is executed. It is actually a XML fragment specifying
  attributes of the GUI element you are looking for and of some of its parents.

### **Misc**

* **Private** - If selected, the values of variables and arguments are no longer logged at Verbose level.

#### Options

* **BlockEvent** - When selected, the key press is blocked from acting on the indicated UI element. By default, this check box is not selected.
* **IncludeChildren** - When selected, the children of the specified UI element are also monitored. By default, this check box is selected.
* **KeyModifiers** - Adds a selected key modifier to the activity. The following options are available: Alt, Ctrl, Shift, Win.
* **TriggerMode** - Specifies if the event is triggered on **Down** or **Up**.
