Lightning Object Specific Actions are a great way to give users the power to do updates with easy configurable functionality; rather than having to build them using any code. They are simple to set up and maintain. They are also easy to add to the List Views; with a couple of clicks. End users (who don’t also have access to anything like ‘Workbench’) may have regular updates they need to do on a weekly, monthly, quarterly basis, and doing exports, data manipulation and upserts would be too time consuming. They can instead create a List View; and use the Mass Update button to select the records they need to update; add in the new value; click save and have all the records update instantly.
Object-specific actions let users create records that have automatic relationships to other records, make updates to specific records, and interact with records in ways that you define.
1. From the management settings for the object for which you want to create an action, go to
Buttons, Links, and Actions.
2. Click New Action.
3. Select the type of action to create.
4. Customize the action.
• For a Create a Record action, select the type of object to create.
– If the object has more than one record type, select the one you want to use for records created through this action.
– If the object for which you’re creating the action has more than one relationship with the target object, select the field you want to populate when a record is created. If the two objects have a master-detail relationship, you can’t select which field to populate.
The master-detail Relationship field is selected by default, and you can’t change this setting.
• For a Custom Visualforce action, select the Visualforce page, and then specify the height of
the action window. The width is fixed.
• For a Lightning Component action, select the component called by the action.
• For a flow action, select the flow to render.
5. Enter a label for the action. Users see this label as the name of the action.
Tip: If you’re creating a Create a Record, Send Email, or Log a Call action, choose an option from the Standard Label Type list to have Salesforce generate the label. For the labels in this list that include “Record” and “Record Type”, Salesforce fills in the type of object or the record type the action creates. For example, if you choose the Create New “Record” standard label on a create contact action, the generated label is Create New Contact.
6. If necessary, change the name of the action.
This name is used in the API and managed packages. It must begin with a letter and use only alphanumeric characters and underscores, and it can’t end with an underscore or have two consecutive underscores. Unless you’re familiar with working with the API, we
suggest not editing this field.
7. Type a description for the action. The description appears on the detail page for the action and in the list on the Buttons, Links, and Actions page. The description isn’t visible to your users. If you’re creating several actions on the same object, we recommend using a detailed description, such as “Create Contact on Account using New Client record type.”
8. For a Create a Record or Log a Call action, select whether you want a feed item to be created when the action is completed.
9. For a Create a Record, Update a Record, or Log a Call action, you can add a custom success message that displays after the action
10. Optionally, click Change Icon to select a different icon for the action. Custom images used for action icons must be less than 1 MB in size.
11. Click Save.
After you create a quick action, customize its layout, add predefined values, and then add the action to page layouts
For Instance; you could have a checkbox on your Account Page to Activate the Account and you want to Mass Update based on list criteria
- Go to Setup – Object Manager – Object (e.g. Account)
- Navigate to Button,Links & Actions
- Click ‘New Action’
- Action Type = Update a Record
- Standard Label Type = If you choose one of these like Update [Record]; Salesforce will use this and the object to name the Action; for example, ‘Activate Account’. If you don’t select this you can name the action yourself
- Name = Underscored Name
4. Edit the Layout by clicking ‘Edit Layout’ button
- Add in fields you need and save
5. Go to the Search Layouts – List View and add in the new button under ‘List View Actions in Lightning Experience’
6. Go to the Object tab and select your View; for example ‘Activate Accounts’ – (Display As ‘Table’)
7. The Action should now appear next to the buttons on the top right hand page
8. Select the records you want to update and then click the Activate Account’ button.
9. Update the value in the relevant field and click ‘Save’
You can also use an existing Quick Update button. Just click ‘Edit Layout’ below and then add in the required field/s:
The Salesforce Help Guide on Object Specific Actions can be found here https://help.salesforce.com/articleView?id=actions_overview_object_specific.htm&type=5
To read more blogs from our team at Hyphen8, Please check out our blog page https://hyphen8.com/blog/