Mass Delete Records (100-150) from List View using Flow #inSalesforce
Create a flow that deletes the selected record
Create screen flow,
Create variable - ids, input - yes, text type, allow multiple checked
Create variable - type -number, called recordCount
Assignment:
Assign Record Count:
recordCount equals Count ids
Decision:
record selected?
zero:
recordCount equals 0 - message select records
greater than zero:
recordCount > 0 and <150 then loop
greater than zero plus:
recordCount >=150 - message - select less than 150
Loop:
collection variable - ids - end of loop message - done
Delete: (loop delete...)
criteria-
Case- Id equals currentItem(loop)Ids
Create a Button that runs the flow
object manager | case | list button | copy the flow url as in the visual
Add button to list view-
Search layouts for Salesforce classic| List View| Add here
Note: Use custom action (https://unofficialsf.com/hydrate-ids-into-records-with-get-records-from-ids/) that converts a text collection that contains IDs to a record collection to maintain the governer limits (you can remove the loop and the delete action inside it)
Visual: https://www.youtube.com/watch?v=z-E5lieNn8g
Comments
Post a Comment