---
title: "action"
description: "Overview"
permalink: /docs/build/ui-components/all-ui-components/object-table/action/
---
# action

## Overview

Similar to [`bind`](/docs/build/ui-components/all-ui-components/#bind), an `action` can be triggered when a user clicks on an `object-table` row. In this case, the specified [`on-press`](#on-press) function will execute.

<Info>

See more information in the guide on `object-table` [actions](/docs/build/ui-components/all-ui-components/object-table/object-table-guides/actions/).

</Info>

### Basic Example

**main.view\.xml**

```xml
<object-table ...>
    <action icon="fa-angle-right" on-press="$:rowAction($selection)" validate="false" />
    ...
</object-table>
```

## Standard Attributes

### `validate`

<SyntaxCard type={"boolean"} defaultValue={"false"} />

Set to `true` to ensure that no required input fields in the current view are empty before performing the [`on-press`](#on-press) action.

```xml
<action on-press="processAction($selection)" validate="true" />
```

## Advanced Attributes

### `icon`

<SyntaxCard type={"string"} defaultValue={"unset"} />

The icon to display on the right end of the row. JourneyApps supports icons from various sources - see [icons](/docs/build/ui-components/all-ui-components/icons/) for details.

```xml
<action icon="fa-user" on-press="processAction($selection)" />
```

## Common Attributes

### `on-press`

<AttributeReference label="on-press" href="/docs/build/ui-components/common-attributes/on-press/" />
