# --Define Row Actions

## Overview

Row actions let you define actions that users can trigger on individual rows of your Data Table. This tutorial walks you through the basics of setting up and configuring those row-level actions.

## Use Case: The "High-Speed Prospector" Dashboard

Imagine you are a Sales Representative with a list of 50 Accounts to review every morning. Usually, you’d have to click into each Account, wait for the page to load, click "Edit," change the Rating, click "Save," and then hit the back button. Doing this 50 times is a recipe for a headache.

The High-Speed Prospector dashboard replaces that tedious process with a single Data Table. Instead of leaving the list, you stay on one screen and use Row Actions to handle your two most frequent tasks: qualifying the lead and researching their business.

## Guided Steps

### The Row Actions Defined

In this scenario, every row in your Account table has a small dropdown menu on the far right containing two specific commands:

#### 1. Action: "Mark as Hot"

* The Interaction: Triggers a Screen Flow.
* The Goal: Quickly update the Account's priority.
* How it works: When you click this, a small window (Flow) pops up. It automatically knows which Account you clicked. You might add a quick note about why they are "Hot," and when you hit "Finish," the Flow updates the `Rating` field to Hot and refreshes the table instantly.

#### 2. Action: "View Website"

* The Interaction: Triggers a Navigate to URL interaction.
* The Goal: Instant background research.
* How it works: Salesforce looks at the `Website` field for that specific row. It then opens that URL in a new browser tab. This allows you to keep your Data Table open in one tab while you browse the prospect's site in the other.

***

### Technical Breakdown

Here is how these two actions differ in their configuration within the Data Table:

| **Feature**    | **Mark as Hot**                        | **View Website**              |
| -------------- | -------------------------------------- | ----------------------------- |
| Trigger Type   | Flow                                   | URL / Navigation              |
| Primary Object | Account                                | Account                       |
| Data Handled   | `RecordId` (passed to Flow)            | `Website` (passed to Browser) |
| End Result     | Database update ($$ $Rating = Hot$ $$) | New browser tab opens         |
| User Benefit   | No manual editing required             | No manual copy-pasting URLs   |

***

### Why this works for Beginners

This use case is the "gold standard" for learning row actions because it teaches you the two main ways Salesforce talks to other tools:

1. Internal Communication: Talking to a Flow to change data inside Salesforce.
2. External Communication: Talking to the Browser to go to a website.

By mastering these two, you can handle about 90% of what users typically ask for in a custom dashboard.


---

# Agent Instructions: Querying This Documentation

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

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.avonnicomponents.com/dynamic-components/tutorials/components/data-table/define-row-actions.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
