# Mouse/Keyboard Action

{% hint style="info" %}
**Block Information**

Available in: Page Flow

Toolbox Category: Action - Event

Block Type: [Regular](https://docs.zingy.ai/app-editor/block-anatomy#regular-block)
{% endhint %}

Use the **`Mouse/Keyboard Action`** block to take an action when the user interacts with elements on the page using the mouse or keyboard.

<div align="left"><figure><img src="https://3401585094-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FmnBepgycwgisXr9ya1N4%2Fuploads%2FGVnAiXu4ZUZVblxSSgKp%2Fimage.png?alt=media&#x26;token=cef72233-3c85-462e-8623-1f34d450969e" alt="" width="293"><figcaption><p>Mouse/Keyboard Action block</p></figcaption></figure></div>

The block consists of the following (from top to bottom):

* *Element*: [Selectable Input](https://docs.zingy.ai/app-editor/block-anatomy#selectable-input) to choose the element.
* *Event*: [Dropdown configuration setting](https://docs.zingy.ai/app-editor/block-anatomy#dropdown) that allows you to choose from three options:
  1. Clicked: When the selected element is clicked.
  2. Double-Clicked: When the selected element is double-clicked.
  3. Right-Clicked: When the selected element is right-clicked.
  4. Key Pressed: When a key is pressed with the focus is inside the selected element.
* *Tasks*: a [Flow Parameter](https://docs.zingy.ai/app-editor/block-anatomy#flow-parameters) where you connect blocks that specify what you want done when the event occurs. Use the [Action/Event Info](https://docs.zingy.ai/app-editor/page-flow/toolbox-blocks/action-event-info) block to get more information about the event.

***

## Usage Example

The image below shows an example of the Mouse/Keyboard Action block where the [Show Information Popup](https://docs.zingy.ai/app-editor/page-flow/toolbox-blocks/show-information-popup) block is used to show a message.

<div align="left"><figure><img src="https://3401585094-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FmnBepgycwgisXr9ya1N4%2Fuploads%2FpYYaWBPBgf5oXswSMVft%2Fimage.png?alt=media&#x26;token=243ab567-4e98-4dd0-aca4-89db9c0b8a81" alt="" width="563"><figcaption><p>Example of Mouse/Keyboard Action block</p></figcaption></figure></div>
