> For the complete documentation index, see [llms.txt](https://docs.avonnicomponents.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.avonnicomponents.com/flow/tutorials/interactions/how-to-create-an-interaction-to-a-record-page.md).

# Open a record from a Data Table row

Add View and Edit row actions to a Data Table of opportunities so a sales rep opens the record page or its edit form straight from the row they clicked.

A sales rep scans their open opportunities on a flow screen and wants the full record of one deal. Each row gets a menu with **View** and **Edit**. **View** opens the opportunity's record page, **Edit** opens its edit form, both on the row the rep clicked.

<figure><img src="https://27923732-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F1FUd4apB9YHgCEMUFbVb%2Fuploads%2FP8mEtem4hbtv2T8ZTsiM%2Fnavigate-how-to-create-an-interaction-to-a-record-page-result.png?alt=media" alt="Opportunity record page opened from the View row action of the Data Table"><figcaption><p>View opens the record page of the row the rep clicked.</p></figcaption></figure>

## Before you start

* A screen flow with an Avonni Data Table of open Opportunities, with **Data Source** set to **Query** or **Variable**. The row's fields are only offered to the interaction with those two sources.
* An Action column with two row actions: **Label** `View`, **Name** `view` and **Label** `Edit`, **Name** `edit`. [Creating Row Actions](https://docs.avonnicomponents.com/flow/tutorials/components/data-table/creating-row-actions.md) shows how.

## Steps

{% stepper %}
{% step %}

### Add a Row Action interaction for View

1. Select the Data Table, click **Open Component Builder** and open the **Interactions** tab.
2. Add a **Row Action** interaction.
3. In **Target Name**, pick **View**. The list shows the row actions by their label.
4. Set **Type** to **Navigate** and **Page Reference Type** to **Record Page**.
   {% endstep %}

{% step %}

### Point it at the clicked record

* **Object Api Name**: `Opportunity`.
* **Record Id**: pick **Record: Id** in the list. It stands for `{{Record.Id}}`, the Id of the row the rep clicked.
* **Action Name**: **View**.

**Record Id** lists the table's Id and lookup fields. Pick the Account Id field instead (`{{Record.AccountId}}`) and set **Object Api Name** to `Account` to open the deal's account.
{% endstep %}

{% step %}

### Repeat for Edit

Add a second **Row Action** interaction with **Target Name** **Edit**, the same **Object Api Name** and **Record Id**, and **Action Name** **Edit**. **Clone** works the same way: it opens a new record form copied from the row.

All the Record Page fields are listed in [Navigate: Record Page](https://docs.avonnicomponents.com/flow/component-builder/interactions-panel/navigate.md#record-page).
{% endstep %}

{% step %}

### Save and test

Click **Done**, save the flow and run it. Open the menu on a row and click **View**: the opportunity's record page opens in the same window. Go back, click **Edit** on another row: the edit form of that opportunity opens.
{% endstep %}
{% endstepper %}

{% hint style="info" %}
From a row action, a Record Page opens in the current window, so the rep leaves the flow screen. To keep the flow open, send the record to a console subtab: [Open records in Console tabs and subtabs](https://docs.avonnicomponents.com/flow/tutorials/interactions/open-records-in-console-tabs-and-subtabs.md).
{% endhint %}

## Troubleshooting

<details>

<summary>The click opens the wrong record or an error page</summary>

**Record Id** and **Object Api Name** do not match. `{{Record.AccountId}}` needs **Object Api Name** `Account`, `{{Record.Id}}` needs the table's own object.

</details>

<details>

<summary>Record Id only offers Custom and Record: Id</summary>

The table's fields are not loaded, usually because the **Data Source** is **Manual**. Set the **Data Source** to **Query** on `Opportunity`, then reopen the interaction. `{{Record.Id}}` still works with **Record: Id**.

</details>

## Related tutorials

* [Add a New Opportunity button that opens a prefilled record form](https://docs.avonnicomponents.com/flow/tutorials/interactions/how-to-create-an-interaction-to-navigate-to-an-object.md): a header button for the New action.
* [Open records in Console tabs and subtabs](https://docs.avonnicomponents.com/flow/tutorials/interactions/open-records-in-console-tabs-and-subtabs.md): the same View action, in a console subtab.
* [How to create an interaction to open another flow](https://docs.avonnicomponents.com/flow/tutorials/interactions/how-to-create-an-interaction-to-open-another-flow.md): run a second flow on the clicked row instead.
* [Expression Syntax in Interactions](https://docs.avonnicomponents.com/flow/tutorials/interactions/expression-syntax-in-interactions.md): how `{{Record.Id}}` and the other item variables work.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.avonnicomponents.com/flow/tutorials/interactions/how-to-create-an-interaction-to-a-record-page.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
