Screen Flow in Salesforce

A Screen flow in Salesforce is a user-interactive flow where the user directly interacts with the UI created by the Screen flow. For example, if a user wants to create a Lead record, the user has to enter the required fields in the UI created by the screen flow to do so.

In this Salesforce tutorial, we will learn about screen flows in Salesforce. Using an example, I will also explain the process of creating a record with Screen Flow.

What are Screen Flows in Salesforce

In Salesforce, Flow is a tool for automating business procedures. It is used to create custom flows, one of which is Screen flow, a primary and widely used flow.

Screen flows provide instructions or call scripts, direct users to complete certain fields, and perform actions like creating and updating a record, and all of this is done in just a few clicks without writing any code.

The Screen element is the feature that distinguishes the screen flow from the other flows. A single screen flow in Salesforce can have multiple screens, and this screen will also be visible to users.

On the screen flow, the components panel on the left represents the items available to be displayed within the screen element.

Here, you will find standard components, such as picklists and text, and custom components that have either been developed internally or come from managed packages. 

Create a Salesforce ScreenFlow

To create a Salesforce flow, navigate to Salesforce’s Setup page and follow the steps below.

In the steps below, I will explain the process of creating a screen using a real-time scenario.

While working for an organization that provides software solutions, I was assigned the task of creating a flow to create a new account record to onboard new clients.

I decided to create a Screen flow, and with this flow, the Sales team will be able to create account records without navigating to the Accounts tab and entering multiple fields.

1. On the setup page, go to the Quick Find box and search, then select Flows under the heading Process Automation.

Create a Screen flow in Salesforce

2. In the Flows setup window, click the New Flow button.

3. In the new flow window, select the option Screen Flow and click on the Create button.

Screen flow salesforce

4. In the Salesforce flow builder, click on the “+” icon below the Start of flow to add an element.

How to create a Screen flow in Salesforce

5. Drag the Screen element to the flow canvas from the Elements tab on the left-hand sidebar.

Create Screen flow in Salesforce

6. In the New Screen window, enter the Label for the screen. In this flow, I have entered the Label as Account details, and the API name will be auto-filled according to the entered label.

Add components from the left sidebar to the screen section. In this example, I will create an account record, so I have added the Section component in which I can add fields.

Create a Screen flow in Salesforce

7. Drag and drop the Text component to the section in the flow screen. Then enter the Label and API Name for the Text field. Then click on the Require button to make this field available.

How to create a record with Screen flow in Salesforce

8. Add the picklist component in the second section and enter the label and API name. In this example, I have named the label as Account type, which keeps the data of the type of account.

Activate the required checkbox to make this field required.

While adding a picklist in the screen flow, you must select the choice resource for each picklist field. To do that, go to the field Choice and click New Choice Resource.

Create a Record with the Salesforce Screen flow

9. Select and enter the following fields in the New Choice Resource window.

  • Select the Resource type as Picklist Choice Set.
  • Write the API name name for the picklist field. For example, I will map this picklist with the Type field of the account object so, I have named it as AccountType.
  • Select the Object as Account and Data type as Picklist.
  • In the Field option, select the default field to which you want to map this screen flow field. For example, this field will take a value for the Type of account, so I have selected the field as Type.
  • At last, click on the Done button.
Use Salesforce flow to create a record

10. Similarly, I have added two more picklist fields, Account Industry and Currency Code. After adding the components and fields on the screen, click on the Done button.

Platform Event Triggered Flow in Salesforce

11. Now the screen is ready, and to insert data in the account table, we need to add the create record element in the flow; for that, click on the “+” icon below the Screen element.

How to use Salesforce Screen flow

12. In the dropdown, select the option Create Records under the heading data.

Create Records with Salesforce Screen flow

13. In this window, enter the label for the record action. In this example, I have named the label Create Account record, and the API Name will be auto-filled according to the label entered.

Activate the radio button; use separate resources and literal values. Then, in the Object field, select the Account object.

Create a Object record with Salesforce Screen flow

14. In the section Set Values for the Account, we have to set the values for the object fields. Here, we will set the values that we have created in the screen element.

I have set object fields Name, Type, Industry, and CurrencyIsoCode with the respective values we created in the Screen element’s choice part.

Click the Save button after setting up the Field Values for the Account (object).

How to set field values to create record with Salesforce Screen flow

15. Enter the Flow Label for the screen flow. In this case, the label is Create New Account Screen Flow, and the API name will be auto-filled according to the entered flow label.

At last, click on the Save button.

How to use Salesforce Screen flow to create records

16. Click on the Activate button to activate the created screen flow.

How to Activate the Salesforce Screen flow

Till we have created the screen flow that will create the Account record.

Add the Screen flow to the record page

To make this screen flow visible to users, we need to add it to a record page, which we will do with the help of Salesforce App Builder.

1. Go to the home page of the application that is accessible to the users, and there, click on the settings icon, and from the options, select Edit Page.

How to Create Screen Flow in Salesforce

2. Now, the home page is opened in the Lightning builder. In this step, drag and drop the Flow component to the template region on the layout of the home page.

Add Screen flow to a record page in Salesforce

3. After this, select the screen flow we created in the flow builder and click the Save button to apply the changes.

Salesforce screen flow to create a record

4. Now, the Screen Flow component will be visible on the home page, and here, enter the fields and click the Next button.

Add record with the help of screen flow in Salesforce

5. Navigate to the object tab for which you have created a record with the Screen flow.

Create a Record using the Screen flow in Salesforce

As we can see in the above image, the record is successfully created in the object with the help of the Salesforce screen flow.

In this way, we can create a screen flow with a flow builder and create a record of that screen flow by following the above steps.

Conclusion

In the Salesforce environment, efficient use of screen flow helps streamline the organization’s automation. In this Salesforce tutorial, you might have got good insights into the Salesforce Screenflow feature.

By following the above steps, you will able to design a screen flow in your Salesforce instance and streamline the automation process in your organization.

You may like to read:

Agentforce in Salesforce

DOWNLOAD FREE AGENTFORCE EBOOK

Start with AgentForce in Salesforce. Create your first agent and deploy to your Salesforce Org.

Salesforce flows complete guide

FREE SALESFORCE FLOW EBOOK

Learn how to work with flows in Salesforce with 5 different real time examples.