Replacing the ‘New’ Opportunity Button on a Contact with a Screen Flow


Description:
An organization seeks to replace the standard ‘New’ button on the Opportunity related list in Contact records with a custom flow. This flow will allow them to create an Opportunity record with additional customization that the standard screen does not offer.

Solution:
In this guide, we’ll walk through the steps to replace the standard ‘New’ button with a custom flow that the admin has already created.

Note: This guide assumes the Flow for creating an Opportunity record is already in place. We will focus on how to replace the standard ‘New’ button with this Flow on the Opportunity related list.

Steps to Implement:

  1. Log in to Salesforce
    • Click the Gear icon in the top right corner.
    • Select Setup from the dropdown menu.
  2. Access the Opportunity Object in Object Manager
    • Navigate to the Object Manager tab.
    • Search for and select the Opportunity object.
  3. Create a Custom Button
    • Under Buttons, Links, and Actions, click on New Button or Link.
    • Fill in the fields as follows:
      • Label: Provide an appropriate name for the button.
      • Name: Assign a suitable API name for the button.
      • Description: Optionally, add a description for clarity.
      • Display Type: Choose List Button.
      • Behavior: Select Display in existing window with sidebar or the option that best suits your needs.
      • Content Source: Select URL.
      • URL: Enter /flow/Create_Opportunity?retURL={!Contact.Id}.
  4. Note:
    • /flow/Create_Opportunity refers to the Flow’s URL.
    • retURL={!Contact.Id} ensures that after the Flow completes, the user is returned to the originating Contact record.
  5. For more details on setting up Flow URLs and return behaviors, check these articles:
  6. Add the Custom Button to the Opportunity Related List
    • Open the Contact object in Object Manager.
    • Go to Page Layouts and select the relevant layout where you want the custom button to appear on the Opportunity related list.
  7. Customize the Opportunity Related List
    • Scroll down to the Related List section, or select Related List from the options.
    • Locate the Opportunity related list and click the wrench icon to edit its properties.
  8. Remove the Standard ‘New’ Button and Add the Custom Button
    • In the Buttons section, click the + icon.
    • Uncheck the New checkbox under Standard Buttons to remove the default ‘New’ button.
    • Under Custom Buttons, move the newly created button from Available Buttons to Selected Buttons.
    • Click OK and save the changes.
  9. Test the New Button
    • Navigate to a Contact record.
    • In the Opportunity related list, you should now see the new button.
    • Click the button to ensure the Flow opens and functions as expected.
Related Posts
Salesforce OEM AppExchange
Salesforce OEM AppExchange

Expanding its reach beyond CRM, Salesforce.com has launched a new service called AppExchange OEM Edition, aimed at non-CRM service providers. Read more

The Salesforce Story
The Salesforce Story

In Marc Benioff's own words How did salesforce.com grow from a start up in a rented apartment into the world's Read more

Salesforce Jigsaw
Salesforce Jigsaw

Salesforce.com, a prominent figure in cloud computing, has finalized a deal to acquire Jigsaw, a wiki-style business contact database, for Read more

Health Cloud Brings Healthcare Transformation
Health Cloud Brings Healthcare Transformation

Following swiftly after last week's successful launch of Financial Services Cloud, Salesforce has announced the second installment in its series Read more

author avatar
get-admin