Automation Champion

Automation Champion

Automating Salesforce One Click at a Time

Running Lead Assignment Rules From Salesforce Flow

Running Lead Assignment Rules From Salesforce Flow

Last Updated on February 14, 2022 by Rakesh Gupta

To understand how to solve the same business use case using Process Builder . Check out this article Getting Started with Process Builder – Part 49 (Running Lead Assignment Rules From Process Builder) .

Big Idea or Enduring Question:

How do you run the lead assignment rule from the Salesforce flow? Lead assignment rules allow us to automatically assign Leads to the appropriate queue or user. A Lead assignment rule consists of multiple rule entries that define the conditions and order for assigning cases. From a Salesforce User interface, a user can trigger assignment rules by simply checking the Assign using the active assignment rules checkbox under the optional section.

The problem arises when you need to insert or update the Leads from Salesforce Flow and wants to trigger assignment rules. Using the Salesforce Flow a Lead will be inserted or updated but the assignment rule will not be triggered as there is no check box to use the organization’s assignment rule or a prompt to assign using the active assignment rule.

Let’s start with a business use case.

Objectives:

After reading this blog post, the reader will be able to:

  • Running the lead assignment rules from Salesforce Flow
  • Understand @InvocableMethod Annotation
  • How to call an Apex method using Salesforce Flow

Business Use Case

Pamela Kline is working as a System administrator at Universal Containers (UC) . She has received a requirement from the management to update the following Lead fields when Lead Source changed to Partner Referra l .

  • Status = Working – Contacted
  • Rating = Hot

As data changed by the process, she wants to fire the assignment rule as soon as the process updates the lead record.

Automation Champion Approach (I-do):

run assignment rules from flow

Guided Practice (We-do):

There are 4 steps to solve Pamela’s business requirement using Salesforce Flow and Apex. We must:

  • Setup a lead assignment rule
  • Create Apex class & Test class
  • Define flow properties for record-triggered flow
  • Add a decision element to check the lead source
  • Add an assignment element to update status & rating
  • Add a scheduled path
  • Add a decision element to check if lead source changed
  • Add action – call an Apex class to invoke lead assignment rule

Step 1: Setting Up Lead assignment Rule

  • Click Setup .
  • In the Quick Find box, type Lead Assignment Rules .
  • Click on the Lead Assignment Rules | New button .
  • Now create an assignment rule, as shown in the following screenshot:

run assignment rules from flow

Step 2: Create an Apex class and Test class

Now, we have to understand a new Apex annotation i.e . @InvocableMethod . This annotation lets us use an Apex method as being something that can be called from somewhere other than Apex . The AssignLeadsUsingAssignmentRules class contains a single method that is passing the ids of the Leads whose Lead Source changed to Partner Referral . Create the following class in your organization.

  • In the Quick Find box, type Apex Classes .
  • Click on the New button .
  • Copy code from GitHub and paste it into your Apex Class.
  • Click Save.

run assignment rules from flow

Step 3.1: Salesforce Flow – Define Flow Properties for Before-Save Flow

  • In the Quick Find box, type Flows .
  • Select Flows then click on the New Flow .
  • How do you want to start building : Freeform
  • Object : Lead
  • Trigger the Flow When : A record is created or updated
  • Condition Requirements: None
  • Optimize the Flow For : Fast Field Updates
  • Click Done .

run assignment rules from flow

Step 3.2: Salesforce Flow – Using Decision Element to Check the Lead Source

Now we will use the Decision element to check the lead source to ensure that it is equal to Partner Referral.

  • Under Toolbox , select Element .
  • Drag-and-drop Decision element onto the Flow designer.
  • Enter a name in the Label field; the API Name will auto-populate.
  • Under Outcome Details , enter the Label the API Name will auto-populate.
  • Resource: {!$Record.LeadSource}
  • Operator: Equals
  • Value: Partner Referral
  • When to Execute Outcome : Only if the record that triggered the flow to run is updated to meet the condition requirements

run assignment rules from flow

Step 3.3: Salesforce Flow – Adding an Assignment Element to Update Rating and Status

  • Drag-and-drop the Assignment Element element onto the Flow designer.
  • Enter a name in the Label field- the API Name will auto-populate.
  • Field: {!$Record.Rating}
  • Add Condition
  • Field: {!$Record.Status}
  • Value: Working – Contacted

run assignment rules from flow

  • Click Save .
  • Enter Flow Label the API Name will auto-populate.
  • Click Show Advanced .
  • API Version for Running the Flow : 53
  • Interview Label : Record-Trigger: Lead Before Save {!$Flow.CurrentDateTime}

run assignment rules from flow

Step 4.1: Salesforce Flow – Define Flow Properties for After-Save Flow

  • Field : Lead Source
  • Operator: Euqals
  • Optimize the Flow For : Action and Related Records

run assignment rules from flow

Step 4.2: Salesforce Flow – Add Scheduled Paths

run assignment rules from flow

  • Under SCHEDULED PATHS , click on the New Scheduled Path .
  • Under Scheduled Path Details , enter the Label the API Name will auto-populate.
  • Time Source : Lead: Last Modified Date
  • Offset Number : 1
  • Offset Options : Minutes After

run assignment rules from flow

Step 4.3: Salesforce Flow – Adding an Action to Call Apex class to Trigger Lead Assignment Rule

  • Drag-and-drop the Actions element onto the Flow designer.
  • Select the AssignLeadsUsingAssignmentRules Apex class.
  • Field: LeadIds
  • Value: {!$Record.Id}

run assignment rules from flow

  • Interview Label : Record-Trigger: Lead After Save {!$Flow.CurrentDateTime}

run assignment rules from flow

Proof of Concept

Now onward, if a business user updates the Lead Source to Partner Referral , Process Builder will automatically update Status , Type , and Assign it to the right user or queue based on the lead assignment rule.

run assignment rules from flow

Monitor Your Schedule Flow

To monitor Flows that are scheduled, navigate to the following path:

  • Navigate to Setup (Gear Icon) | Environments | Monitoring | Time-Based Workflow .

run assignment rules from flow

  • Use the Delete button to delete the time-based Flow job from the queue.

Formative Assessment:

I want to hear from you! What is one thing you learned from this post?  How do you envision applying this new knowledge in the real world? Let me know by Tweeting me at @automationchamp , or find me on LinkedIn.

Submit Query!

Similar Posts

run assignment rules from flow

Easiest Way to Make Screen Component Read Only

run assignment rules from flow

Choose Running User for Platform Event-Triggered Flows

run assignment rules from flow

Automatically Refresh Your Salesforce Dashboard Every Hour or Minute

9 thoughts on “ running lead assignment rules from salesforce flow ”.

It ran repeatedly, every minute, over and over again. I was getting notification email every minute when testing. I did the same steps as you mentionned, with a record triggered flow containing the apex action.

I found that this ran repeatedly, every minute, over and over again. Was easy to spot because I modified the Apex to include sending the user notification email as well – so I was getting notification email every minute when testing.

When I updated the ‘Time Source’ in the flow scheduled path from ‘Time Source: Lead: Last Modified Date’ to ‘Time Source: When Lead is Created or Updated’ that seems to have solved the problem.

Was curious if you had the same experience or if there was some other nuance happening.

It also looks like you had originally intended to use a decision element in step 4.3 but changed that to flow entry requirements, likely because the scheduled path can’t assess the prior and current values the same way the starting node can.

Thank you for sharing your valuable feedback. I have a quick question for you: When executing the Apex class, do you utilize a Record-triggered Flow or a Scheduled-triggered Flow?

after the apex class fires, noticed the lead owner is assigned to default lead owner, instead of using lead assignment rule. Any clue?

Thank you for an excellent tutorial 🙂 you solved my problem! Very much appreciated

Anyone getting issues with an error on mass updates “Apex error occurred: System.QueryException: List has more than 1 row for assignment to SObject “? if each one is called individually, I don’t understand how there is more than 1 row for assignment. Sometimes I get an email with this error only to see that the trigger actually worked for the specified record so a bit odd. Thanks!

Thank you for the great tutorial. Why add the 1 minute wait? Is that just to take avoid too much synchronous automation? Or is it required for another reason?

You’re right Kevin (to make the process asynchronous).

  • Pingback: Getting Started with Process Builder – Part 49 (Running Lead Assignment Rules From Process Builder) - Automation Champion

Leave a Reply Cancel reply

This site uses Akismet to reduce spam. Learn how your comment data is processed .

Discover more from Automation Champion

Subscribe now to keep reading and get access to the full archive.

Type your email…

Continue reading

How to Apply Case Assignment Rules in Flow

May 18, 2023 Yumi Ibrahimzade Actions , Automation , Flow , Flow Actions , Flow Packages , Packages 26

How to Apply Case Assignment Rules in Flow

The case object is a core part of the Salesforce platform. It helps manage and track customer issues and inquiries. You can use this standard object to handle support requests effectively. The case object acts as a central repository for recording and monitoring customer interactions. It allows you to streamline your customer service processes. In order to improve the support efficiency, it is important to assign cases to the right teams or individuals. Although you can manually assign the record, it is possible to use the standard case assignment rules as well. Case assignment rules determine how cases are assigned to users or put into queues.

When you create a new case record, you can just mark "Assign using active assignment rule" to run case assignment rules.

Checkbox to assign case using active assignment rule

However, if you are creating the case record using Salesforce Flow, there is no standard option to run the case assignment rules. This option exists just for lead assignment rules. Moreover, when you create a case using flow, you have to set the correct owner id. Otherwise, the system doesn't run the case assignment rules and assigns the case to the current user. If you really want to use the logic that you have in your assignment rule, you will have to build the same logic again in the flow.

Standard action to apply lead assignment rules

In this post, you can find a custom invocable action (Apex class) that runs case assignment rules for any case record that you want.

How to Use the Action

1-  Install the action using the installation links below.

2-  Add a new action to your flow and search for "Apply Case Assignment Rules", this is the name of the action that you installed.

Add Apply Case Assignment Rules Action

3- Give a name to the action and provide the id of the case record that you want to assign.

Assign case using the custom action

You can use this action in any flow type that supports the action element.

Here is a screen flow that clones a case record with its related records. It uses this custom action to assign the new case record. Read this post to learn how to create a flow to clone a record with its related records.

Installation Links

Use this link to install in production or developer edition environments.

Use this link to install in sandbox environments.

25 Comments

Is that a future method or synchronous?

It is synchronous.

Hi Yumi, I tried using this on a case after save flow as an immediate action on create and it doesn't work. However, if I add a scheduled path of 0 min after creation, it works. Do you know of this limitation? Thanks!

I'm also noticing that this doesn't work when a guest executes a screen flow from a public page which creates the case.

Is your screen flow working in system context - view all data?

Hi Jay, It works in asynchronous path as well. I will check if it is possible to use it in the immediate path.

Thank you, I don't have to code this now.

You are welcome!

Hey Yumi, Case is assigned but email is not fired to members of queue? Any suggestions?

Hi Priyanshu, You are right. I just added it to the code and uploaded the package again. Can you please try with the new version?

Thanks Yumi, Can you please provide the url for new version?

Yumi, waiting for your response.

Is there a way to verify (in a flow decision), using a formula or some other way, if the "Assign using active assignment rule" is checked? I have a user case where the Assignment rules need to be triggered within the flow ONLY when the checkbox "Assign using active assignment rule" is checked, but I cannot find a way to do so. Any ideas?

"Assign using active assignment rule" is not a field on the object, so I think unfortunately it is not possible to get this information.

Hey Yumi Ibrahimzade, Not working in production or can you please provide url for update version? Thanks in advance 🙂

Thank you so much for this package. I just came across the need for this and then found your solution. It works exactly as expected.

I am glad that you found it useful!

Thanks Yumi, It helped me a lot to resolve my issue!

I am glad that you liked it Nadia!

Thanks for the post, Yumi, would you be willing to publish the code in a code snippet?

You are welcome Andy. Here is the code:

public class ApplyCaseAssignmentRules { @InvocableMethod (label='Apply Case Assignment Rules') public static void CaseAssign(List CaseId) { Database.DMLOptions dmo = new Database.DMLOptions(); dmo.assignmentRuleHeader.useDefaultRule= true; dmo.EmailHeader.TriggerUserEmail = true; Case Cases=[Select id From Case Where Case.id in:CaseId]; Cases.setOptions(dmo); update Cases; } }

I am using this action in a trigger flow (After Save), but it's not working, I should a scheduled path if I wanted to work, any suggestions please ? Thank you

Hi, You should use this action in a scheduled or asynchronous path.

I am trying to install in sandbox and getting this error: ApplyCaseAssignmentRulesTest: Method does not exist or incorrect signature: void startTest() from the type Test

Worked perfect in a screen flow with no Scheduled or Asynchronous path.. Thanks!

1 Trackback / Pingback

  • Integrating ChatGPT with Salesforce: A Real-Life Example

Leave a Reply Cancel reply

Your email address will not be published.

Save my name, email, and website in this browser for the next time I comment.

Copyright © 2024 | SalesforceTime.com

run assignment rules from flow

Salesforce is closed for new business in your area.

Get an interactive tour of BookIt for Forms — no demo needed!

  • Intelligent Lead Delivery
  • Convert Signals to Revenue
  • Enterprise Salesforce Orchestration
  • Products Overview Discover modern Revenue Orchestration
  • Integrations Connect signals to plays
  • Pricing Plans for every company
  • Why LeanData

Featured Customers

Snowflake Scales Account Based Plays with LeanData Revenue Orchestration

Clockwise Supports PLG Motion with LeanData Revenue Orchestration

Clockwise Supports PLG Motion with LeanData Revenue Orchestration

  • Become a Partner Team up with LeanData
  • Technology Partner Directory Discover ISV solutions to fit your needs
  • Solutions Partner Directory Connect with our network of authorized Service Integrators

run assignment rules from flow

LeanData’s integration with Salesloft allows a user to route prospects to the right reps.

Slack

Slack has transformed business communication– it’s the platform where work can happen.

run assignment rules from flow

Expertly target and engage high-value accounts when they’re ready to buy.

Outreach

LeanData’s integration with Outreach allows a user to route prospects to the right reps.

Resources

  • Learning Center
  • Certification
  • Tips & Tricks
  • Help Center
  • About Us Learn more about us and our mission
  • Newsroom Keep up with what’s new at LeanData
  • Events Stay up to date and network with industry professionals at our upcoming events
  • Careers Join the LeanData team
  • Contact Us Get your questions answered - contact us now

G2 Recognizes Lead-to-Account Matching and Routing as Newest Tech Category, with LeanData the #1 Vendor

G2 Recognizes Lead-to-Account Matching and Routing as Newest Tech Category, with LeanData the #1 Vendor

Leandata showcases power of modern revenue orchestration at opsstars 2022, leandata announces winners of the 2022 opsstars awards, what are lead assignment rules in salesforce.

Lead assignment rules are a powerful feature within Salesforce to assist your team’s automation of its lead generation and customer support processes. Assignment rules in Salesforce are used to define to whom your Leads and Cases (customer questions, issues or feedback) are assigned based on any one of a number of specified criteria you determine. 

Organizations typically develop lead assignment rules for their GTM processes or flows:

  • Rules for inbound Leads
  • Rules for website-generated Leads
  • Rules for importing Leads from an event

For case assignments, a company might establish one case assignment rule for weekdays and another assignment rule for weekends and holidays. 

A lead or case assignment rule often consists of multiple rule entries to specify exactly how leads and cases are assigned throughout your go-to-market teams. For example, related to customer service inquiries, a standard case assignment rule might have multiple entries. Cases with “Type equals Gold” are assigned to the Gold Level service queue, cases with “Type equals Silver” are assigned to the Silver Level service” queue, and so on. 

flowchart with arrows and people

As organizations grow and scale, they operationalize multiple GTM motions: inbound, outbound, account-based, upsell/cross-sell, and hybrid. However, many are limited to having just one rule in Salesforce.

As a work-around, many organizations create one massive lead assignment ruleset. They then wedge all of their rule entries into that one big ruleset, regardless of how many different motions that represents. Over time, Salesforce lead assignment rules can quickly become unmanageable .

This post covers the best practices for Salesforce lead and case assignment rules. The ultimate goal is to fully engaging your hard-won leads and speed up your organization’s time-to-revenue.

How to Define Assignment Rules

Your Salesforce administrator can only have one rule in effect at any particular moment in your go-to-market motions, and that assignment rule is intended to both automate lead generation processes and other customer-facing processes routed through your CRM. 

Lead assignment rules specify how leads are assigned to users or queues as they are created manually, captured from your website, or imported via SFDC’s Data Import Wizard.

Case assignment rules determine how cases are assigned to users or put into queues as they are created, either manually or through the use of Web-to-Case, Email-to-Case, On-Demand Email-to-Case, the Self-Service portal, the Customer Portal, Outlook, or other data generation applications.

Criteria for Lead Assignment Rules

Okay, so you’ve decided that lead assignment rules in Salesforce make sense for your revenue operations team – now what?

Well, first, you’ll need to determine the edition of your Salesforce instance. Lead assignment rules are available in the Group, Essentials, Professional, Enterprise, Performance, Unlimited, and Developer Editions of SFDC. Case assignment rules, conversely, are available only in the Professional, Enterprise, Performance, Unlimited, and Developer editions.

With regard to User Permissions, to view assignment rules, you’ll need View Setup and Configuration permissions. However, to create or change assignment rules, you’ll need Customize Application. If you are not your organization’s Salesforce administrator, you should check with them before attempting to head off on your own.

lead-assignment-rules-criteria

How to Create Salesforce Lead Assignment Rules

Creating lead and case assignment rules in Salesforce is a relatively straightforward process. 

  • Login to Salesforce and select Setup in the upper right corner of the horizontal navigation bar.
  • In the Setup search box , type “assignment rules” and then select either Lead Assignment Rules or Case Assignment Rules.
  • Select New to create a new assignment rule.
  • In the Rule Name box, type a name and specify whether it should be active for leads or cases created manually and by those created automatically by web and email. When done, click Save .
  • Click open your newly created rule and select New in the Rule Entries to specify your rule criteria.
  • Step 1 in the “Enter the rule entry” window requires you to enter an Order for your new rule (the Order is the order in which the entry is processed, like a queue).
  • In Step 2, you determine whether your new rule is based on meeting a set of criteria or a formula. In the Run this rule if the dropdown box, select either “criteria are met” or “formula evaluates to true.”
  • Lastly, in Step 3, select the user or queue to whom your rule will assign your new lead or case (use the lookup feature to find specific users or a queue). After completing Step 3, select Save .

Why Are Your Salesforce Lead Assignment Rules Not Working?

If you discover your lead or case assignment rules are not working, here are a few tips to quickly troubleshoot the root cause.

First, check to ensure the assignment rule is active. Remember, only one case or lead assignment rule can be active at one time. Secondly, ensure the record is assigned to the correct user or queue.

Make certain to select the checkbox Assign using active assignment rule . In support of this step, enable field History tracking on case or lead owner, as well as add object History (case or lead) in your page layout. 

One common problem is overlapping rule entries, or rule entries in the wrong order. With dozens of rule entries, many will overlap, causing records to get assigned unpredictably. For example, if entry #1 assigns California leads to John, and entry #2 assigns Demo Request leads to Jane, then John might wonder why he’s receiving Demo Requests leads who are supposed to go to Jane. 

Assignment Rule Examples

The image, below, shows sample rule entries being entered into Salesforce for a variety of “what if” situations:

  • Junk leads containing “test” are sent to an unassigned queue
  • Demo requests are routed directly to SDR 3
  • Leads at accounts with over $100 million in annual revenue are routed to AE 1
  • Leads in certain states are sent to their respective representatives

sample-lead-assignment-rules

How LeanData Simplifies Salesforce Lead Assignment

Creating lead and assignment rules in Salesforce is relatively straightforward. However, as your GTM motions become more and more complex, it becomes necessary to populate that one rule with multiple defining rule entries. As you grow and scale, your rule threatens to become unwieldy. Then these problems arise:

  • Difficulty in both comprehending and managing
  • Poor visibility, making it difficult to troubleshoot and validate
  • Restrictions allowing only the criteria on the routed record

salesforce-lead-assignment-rules-example

LeanData’s lead routing flow and assignment solution is a native Salesforce application that allows users to create flows in an easy-to-understand visual graph. Its visible representation of an organization’s desired lead flow affords many benefits to users, including:

  • Easier ability to visualize and understand complex flows
  • Real-time visibility of the routing of leads and the ability to quickly troubleshoot and make adjustments
  • At-a-glance ability to use information on matched records for routing decisions and actions

leandata-routing-assignment-flow

Assignment rules in Salesforce are a relatively easy-to-learn feature that can be very quickly implemented, delivering a flexible and powerful logic to your CRM processes. Automating your lead and customer processes will accelerate your GTM motions and deliver your organization a sustainable competitive advantage.

For more best practices, read the eBook, “ Best Practices for a Winning B2B Marketing Data Strategy .”

  • lead assignment rules
  • lead assignment rules salesforce

run assignment rules from flow

Ray Hartjen

Ray Hartjen is an experienced writer for the tech industry and published author. You can connect with Ray on both LinkedIn  &  Twitter .

More Related Content

How to Automate Lead Routing in Salesforce

How to Automate Lead Routing in Salesforce

How assignment rules work in Salesforce When leads come into your Salesforce instance, a rep needs to reach out to...

Salesforce Lead-to-Account Matching, the Easy Way

Salesforce Lead-to-Account Matching, the Easy Way

Salesforce lead-to-account matching is an important consideration in better aligning Sales with Marketing and increasing the efficiency and productivity of...

10 Best Lead Assignment Tools for Revenue Teams (2024)

10 Best Lead Assignment Tools for Revenue Teams (2024)

Lead assignment tools optimize sales processes by building efficiency into lead distribution. Here are the top 10 lead assignment tools worth investigating.

Getting Started With Assignment Flows

For the most part, assignment rules are difficult to visualise and manage in salesforce. complete leads makes it easy to create and manage assignment rules, for teams of variable sizes and complexities, in a flow-chart-style ui. 5-aug-2022 • knowledge, the ‘what’.

image.png

Creating a New Flow

image.png

Activating your flow

image.png

Filter Records By Criteria  

image.png

Multiple Criteria Filter

image.png

Assign Round Robin

image.png

Assign Matched Lead Owner (Lead records only)

image.png

Account Based Assignment (Lead records only)

image.png

Assign to User or Queue

image.png

Re-Run Salesforce Lead Assignment Rules (Lead records only)

image.png

Duplicate Rule Match

image.png

Custom Match

image.png

Create Record

image.png

Update Match

image.png

Field Update

image.png

Email Users

image.png

Slack Notification

Convert leads (lead records only).

image.png

Record Auto Merge

image.png

  • Winning lead has a value for Phone, Email, Annual Revenue.
  • Losing lead has a value for Phone, Email, Employee Count, Industry.
  • Winning Lead retention will result in a lead with Phone, Email, Annual Revenue values preserved.
  • Losing Lead retention will result in a lead with Phone, Email, Employee Count, Industry preserved.
  • “Both” retention will result in a lead with Phone, Email, Annual Revenue, Employee Count, and Industry.
  • If your winning lead is the newest lead, you may want to keep all values from the winning lead by default but keep a Do Not Call value set to TRUE if this value exists on the older lead.
  • If you always want to keep a Lead Status that's further down the funnel, you can prioritize the value of SQL, then MQL, then AQL if either lead has that status.

Nested Flows

image.png

Additional Features

Response timer, lead conversion, implementation.

Contact your respective Customer Success Manager for any questions/assistance when creating your assignment flows.

System Information

Related articles.

  • Number of Views 432
  • Number of Views 312
  • Number of Views 189
  • Number of Views 460
  • Number of Views 309

Trending Articles

  • Traction Hierarchies End User Guide
  • Working with Multiple Hierarchies
  • Install Traction Complete from the AppExchange
  • Complete Company
  • Internal Match Rules Setup

run assignment rules from flow

Logo

Case Assignment Rules triggering

Sooooooooo - Case Assignment Rules (I'll abbreviate this to CAR) don't actually trigger automatically and never do.

To trigger an assignment rule, a user must ALWAYS select "assign using active CAR".

The thing is, you can both hide this checkbox, and set it to TRUE by default.

So the user thinks they saved a case, but in effect they used a CAR MANUALLY.

What's fun is that when you load data, sometimes you need to process Assignment Rules. In the dataloader, this is done by specifying, manually, the assignment rule ID that you want to trigger. This can only be done by the Salesforce Data Loader as far as I know. Added fun !

So what does this have to do with your case ?

Turns out the ONLY way to trigger CAR on a case programmatically is with a trigger. You can't do it with a flow. You can't do it with a process builder. You just need to use DML.Opts.

A VERY simple trigger I copied from a Salesforce Board some time ago is below. Note that using this out of the box is bad. You want a dev to go over it and check your use case, as well as existing automations. Also you may notice that this is not best practice because everything is in a trigger. Short version this is an EXAMPLE and should NEVER be used in production.

anyway this will be the case for:

- social post cases

- community cases

- any whatever case that is created programatically.

No Comments

TheSyllaGroup-Your-Agile-and-Digital-Par

Cloud SYlla

Your Agile & Digital Partner

  • Mar 2, 2023

Understanding Assignment Rules: A Comprehensive Guide

run assignment rules from flow

Assignment rules are an important feature of Salesforce that help businesses automate assigning records to specific users or teams based on predefined criteria. This article will discuss assignment rules, how they work, and the benefits they provide to businesses.

What are Assignment Rules?

Assignment rules are a set of criteria that are defined by businesses to determine how records should be assigned to users or teams within the Salesforce system. These criteria can be based on several factors, such as the record type, location, record status, or the user's role or territory. For example, a company may set up an assignment rule to automatically assign a new lead to the sales rep who covers that particular region or product line.

How do Assignment Rules Work?

When a record is created or updated, the assignment rules evaluate the record based on predefined criteria. The assignment rule automatically assigns the record to the designated user or team if the criteria are met. Once the record is assigned, the user or team can work on the record.

Salesforce provides a simple wizard that enables administrators to set up assignment rules. The wizard allows administrators to define the criteria for the assignment, select the user or team to assign records to, and set up any needed notifications or escalations.

How to Set Up Assignment Rules in Salesforce

run assignment rules from flow

Setting up assignment rules in Salesforce is a straightforward process that requires the following steps:

Identify the criteria for record assignment - Before creating an assignment rule, businesses should first identify the criteria used to assign records. It might include the record type, location, user role, or other custom fields.

Create the assignment rule - Once the criteria have been identified, businesses can create the assignment rule in Salesforce. It involves setting up a rule that evaluates the criteria and assigns records to the appropriate user or team.

Test the assignment rule - After the assignment rule has been created, businesses should test it to ensure it is working correctly. It might involve creating test records and verifying that they are assigned to the correct user or team.

Activate the assignment rule - Testing it in Salesforce will allow it to be activated. It allows it to automatically assign records to the appropriate user or team.

Types of Assignment Rules in Salesforce

run assignment rules from flow

Salesforce offers two types of assignment rules: standard assignment rules and lead assignment rules.

Standard assignment rules assign records to users or teams based on predefined criteria. They can be set up for various record types, including leads, cases, and opportunities.

Lead assignment rules are specific assignment rules used to assign leads to sales reps. They evaluate the criteria for a lead, such as location or product interest, and assign the lead to the appropriate sales rep based on a round-robin or customized assignment method.

Benefits of Assignment Rules

There are several benefits to using assignment rules in Salesforce, including:

Increased Efficiency

One of the most significant benefits of assignment rules is their increased efficiency. By automating the process of assigning records, sales, and customer support teams can spend less time manually assigning leads and cases to the appropriate users or teams. They can focus on more important tasks, such as following up with leads, resolving customer issues, and closing deals.

With assignment rules, businesses can streamline their processes and reduce the time it takes to respond to customer inquiries, ultimately improving their overall efficiency and productivity.

Improved Customer Satisfaction

Another important benefit of assignment rules is the improved customer satisfaction they can provide. Businesses can automatically assign cases to the appropriate user or team to ensure that customer inquiries are handled promptly and efficiently. Customers receive faster responses to their inquiries, which can help improve their overall satisfaction with the company.

In addition, by assigning cases to users with the appropriate skills and knowledge, businesses can ensure that customer issues are resolved more effectively, further improving customer satisfaction.

Accurate Data

Assignment rules also help businesses maintain accurate data in their CRM system. By automating the process of assigning records, businesses can ensure that data is entered correctly and consistently. It means that reports and analytics generated from the data are more accurate and reliable, which can help businesses make more informed decisions.

In addition, businesses can use assignment rules to enforce data validation rules, which can help prevent incorrect data from being entered into the system.

Consistency

Another benefit of assignment rules is that they help ensure consistency in record assignments. By automating the process of assigning records, businesses can ensure that records are assigned to the appropriate user or team consistently. It reduces the risk of errors or omissions occurring when records are manually assigned.

In addition, by using assignment rules to enforce a standardized process for record assignment, businesses can ensure that records are handled consistently across different teams and regions.

Flexibility

Finally, assignment rules provide businesses with great flexibility in assigning records. Businesses can define complex rules based on various criteria, such as record type, location, or user role. Businesses can customize their assignment rules to fit their specific needs and workflows.

In addition, assignment rules can be updated or modified as needed, allowing businesses to adapt to changes in their business or industry.

Best Practices for Using Assignment Rules in Salesforce

Businesses should follow these best practices to ensure Salesforce assignment rules are working effectively:

Define clear assignment criteria: Before setting up assignment rules, businesses should define clear criteria for record assignments. It will help ensure that records are assigned accurately and consistently.

Test assignment rules before activation: Before activating assignment rules, businesses should test them to ensure that they are working correctly. It will help prevent errors and ensure that records are assigned to the appropriate user or team.

Monitor and adjust assignment rules: It is important to monitor them regularly to ensure they are working properly. Businesses should also be prepared to adjust assignment rules as needed to accommodate changes in their business or industry.

Communicate changes to users: When changes are made to assignment rules, businesses should communicate with them to ensure they are aware of any changes in their workload or responsibilities.

In conclusion, assignment rules are a powerful feature of Salesforce that helps businesses automate assigning records to specific users or teams. The benefits of assignment rules include increased efficiency, improved customer satisfaction, accurate data, and consistency.

By using assignment rules, businesses can streamline their processes, improve their overall effectiveness, and achieve their goals more efficiently.

At Cloud Sylla, our sole focus is on assisting businesses in achieving success through digital transformation. Our goal is to aid customers in making the crucial shift to digital technologies, enabling them to bolster their strategies, multi-channel distribution, and internal operations.

Recent Posts

What is Record-Triggered Flow in Salesforce? Detailed Guide

How to Get & Reset Security Token in Salesforce? (Detailed Guide)

What is Sharing Rules? How can you Create it in Salesforce? (Complete Guide)

Comentarios

run assignment rules from flow

How to Re-run Salesforce Lead Assignment Rules: Process Builder & Apex

Note:  On Sep 23, 2021, Salesforce announced they’re deprecating Process Builder in “Summer 2022.”  And they cautioned , “the best way for you to future-proof your organization is to move your automation to Flow.”  This Process Builder tutorial is still accurate, but we recommend reading and following the Flow tutorial instead.

Salesforce Lead assignment rules are a powerful tool to make sure that Leads are assigned to the appropriate user or queue for follow up. They also allow marketers to get and stay out of the business of trying to maintain sales territory logic within their Marketing Automation Platform (MAP).

When a new Lead is created, Salesforce will use the logic you’ve configured to assign the record to the appropriate user or queue. But what if you need to re-run that logic on existing records? If you only need to do this for a single Lead record, the solution is as simple as editing the record and selecting the optional “Assign using active assignment rule” checkbox.

>> Related: 6 Ways to Handle Those Pesky Spambot Clicks in Marketo <<

In this post:

What it looks like

Here’s an example of what that looks like:

Edit Lead Screenshot with Assign box checked

If you need to do a one-time batch reassignment of a number of records, you can export the relevant Lead Ids and use the Apex Data Loader to trigger assignment rules to fire. You can grab the ID of the appropriate Lead Assignment Rule from the URL bar when viewing the rule in Setup. It will always start with the prefix “01Q”.

Assignment Rule Id from URL bar

Re-Run Salesforce Lead Assignments

There are times where you want to re-run assignment rules automatically under certain conditions. For example, you may assign Leads under a certain Lead Score to a Queue. When the Lead Score increases over the threshold, you then want to re-run assignment rules to assign to an inside sales rep for follow up.

In order to accomplish this, we can use the extremely powerful combination of Process Builder and an Apex Invocable method. This allows you to take advantage of the power of Apex with the flexibility to declaratively (clicks, not code!) control the logic of when to re-run the assignment rules without having to edit any code.

Using Apex for Salesforce Lead Assignment Rules

Let’s start with the code. Since we’re writing code here, we’ll need to start in a sandbox org first before deploying to production. You’re smart and already knew that you’d NEVER make changes in production without first testing in a sandbox ( right?! ), but in this case, Salesforce doesn’t trust you either way and forces you to write your code in a sandbox org before moving to production.

We’ll be creating an Apex class with a single method with the @InvocableMethod annotation, which allows us to call our Apex from within a Visual Flow or Process. The method accepts a single parameter (a list of the Lead Ids to be assigned) that you’ll pass into the method from your Process.

That’s it. Just those four lines are all you need in your code. The rest of your logic for when to actually fire the assignment rules will be configured in Process Builder.

Now, in order to actually deploy this to your production org, you’ll also need to create a test class to cover your code and ensure that it functions as expected in your environment. A sample test class might look like this, but this is extremely basic. I suggest working with a developer to make sure you’re doing everything properly and accounting for any additional requirements specific to your Salesforce instance.

Using Salesforce Process Builder for Salesforce Lead Assignment Rules

Now that we have our code to reassign our Leads, we’ll create our declarative logic of when to fire it using the Process Builder.

1) Create a new Process by searching for the Process Builder under Setup and clicking the New button in the top right. Give your process a name, and set the option for “The process starts when” to “A record changes” as shown in the screenshot below.

New Process Window

2) Select the Lead object for your Process and start the process when a record is created or edited.

run assignment rules from flow

3) Click on Add Criteria, and give your criteria a name. In this example, we’ll be exploring the earlier use-case of wanting to re-assign Leads after they meet a certain Lead Score. We’ll select “conditions are met” and set the condition that the Lead Score is greater than or equal to 100. Under the advanced section, we’ll select the option to only execute the actions when specified changes are made to the record. This means that we’ll only execute the actions if the record previously did not meet the criteria but now does after being updated.

Process Action Criteria

4) Without getting into too much detail, because of Triggers and Order of Execution , we can’t call our code in an immediate action. Instead, we’ll create a scheduled action to call our Apex method. In this case, we want the logic to execute as quickly as possible, so we’ll set the schedule for 0 hours from now.

Process Set Schedule

5) Once saved, we can create our scheduled action. Click Add Action, and select the Action Type Apex. Give your action a name, and select the Apex class you created earlier. Set the Apex Variables leadIds using the Field Reference of the Lead Id that started the process.

Scheduled Action

6) After saving, you can activate your process and test in your sandbox to ensure functionality before deploying to your production org. Since the code is fired under a scheduled action, there is a slight delay before the reassignment happens. In my experience, this is usually less than two minutes, but you can monitor this under Setup > Flows and viewing the Paused and Waiting Interviews section.

Scheduled Action Monitoring

Once you’ve tested and are satisfied that everything is working properly, you can deploy this up to your production org and start taking advantage of this right away. The nice part about this particular approach is that if your requirements change””for example if your Lead Score threshold changes to 150 instead of 100″”you can change the logic in your Process without having to touch any code.

run assignment rules from flow

You might also like

run assignment rules from flow

Sales Funnel ROI Calculator

run assignment rules from flow

Checklist: How to Audit a Salesforce Instance

run assignment rules from flow

8 Lead Management Process Samples

Get our newsletter.

Get tips, tutorials, best practices, and other cool stuff delivered to your inbox every quarter.

  • Name * First Last

Get a System Audit

Whether you inherited a new instance or just want a second opinion, we'll dive in and benchmark your tech stack.

  • Full Name *
  • Job Title *
  • What systems and challenges do you have?* *
  • Hidden utm_medium
  • Hidden utm_source
  • Hidden utm_campaign
  • Hidden utm_content
  • Hidden utm_term

Download Resource

Use this form to recieve your free resource in your inbox today!

Utah high school removes class assignment on student essay titled ‘It Is So Hard to Be Trans’

The essay, published in the new york times, contained no explicit or “pornographic” content that would have required its removal under utah law..

(Google Maps) Herriman High School, as shown in a 2021 Google Maps image, in Herriman, Utah. Jordan School District officials ordered that a class assignment at the school involving a transgender student's essay be removed.

Jordan School District officials ordered that an assignment involving a Texas student’s essay published in The New York Times titled “It Is So Hard to Be Trans” be removed from a Herriman High School class’s curriculum after it was brought to the attention of administrators.

“We apologize to any student offended by a Herriman High School classroom assignment involving a New York Times student essay and the disruption to learning it may have caused,” district spokesperson Sandra Riesgraf said in a statement Monday.

The district investigated the assignment, “which asked students to break down parts of speech in the essay,” after school administrators were notified, Riesgraf said. The assignment was ultimately removed and is “no longer part of the class.”

“Appropriate administrative action will be taken,” the statement continued, though the statement did not specify what that action would entail.

The district also did not specify why the assignment was removed. The content does not seem to violate Utah’s sensitive materials law .

But it did seem to prompt outrage after photos of the printed-out, stapled essay made rounds in conservative social media circles as early as last Thursday, with some posts claiming students were required to write a response to the essay explaining why being transgender “isn’t a choice.”

Riesgraf said that claim was false. “Students were not required to take a stance or form an opinion on why being trans isn’t a choice,” Riesgraf said. “The assignment was to review the writing, not the subject.”

Sen. Dan McCay, R-Riverton, weighed in on X , formerly Twitter, arguing that he didn’t see how the essay would “fit into any curriculum that is state approved.”

“I’ve asked the district to investigate,” he wrote.

McCay did not immediately respond to a request for comment from The Salt Lake Tribune.

The assigned essay had been selected as one of the Top 11 winners in a 2023 student editorial contest through the The Learning Network, a free resource for teachers curated by The New York Times.

It was written by then 16-year-old Callisto Lim, a student at the Kinder High School for the Performing and Visual Arts in Houston, Texas. The essay details why Callisto felt scared for their “right to exist,” citing several states that had passed anti-transgender legislation.

“I am scared that if I stay in Texas I will be denied the health care that I need because of people like Governor Greg Abbott,” Callisto wrote.

Callisto’s essay contains no explicit “pornographic or indecent material” that would make it illegal under Utah’s current sensitive materials law.

Utah law also does not explicitly prohibit classroom discussion of sexual orientation and gender identity, though lawmakers have made attempts to pass legislation banning such topics in the past.

Earlier this year, Rep. Jeff Stenquist , R-Draper, proposed a bill that would have prevented school officials from “endorsing, promoting, or disparaging certain beliefs or viewpoints,” building upon existing restrictions meant to uphold “constitutional freedom” in Utah public schools.

The bill would have specifically added “gender identity,” “sexual orientation,” and “political and social viewpoints” as restricted topics, but it ultimately failed to pass .

A year prior, Stenquist also ran a bill that would have prohibited any discussion of sexuality, sexual orientation and gender identity in kindergarten through third grade. HB550 took language directly from a controversial Florida bill that became more widely known as the “Don’t Say Gay” measure.

But after pushback from the LGBTQ community, Stenquist revised his draft , lifting the proposed ban on sexual orientation and gender identity but keeping the prohibition on sexuality. The bill failed to pass.

author

Donate to the newsroom now. The Salt Lake Tribune, Inc. is a 501(c)(3) public charity and contributions are tax deductible

RELATED STORIES

Utah plan to ban pride flags in classrooms is rejected by house, transgender jordan school district student speaks out as adults discuss school restroom use, school districts await statewide book ban list as utah plans to retroactively enforce new law, weber state university takes utah nurse to next level in life, career., opinion: college students who are protesting are not terrorists, and they shouldn’t be treated as such, opinion: as stem cell biologists, we’re concerned a utah law will lead to a boom in snake oil sales, utah gov. cox calls affordable housing crisis an ‘existential crisis’ on par with covid, opinion: can nonprofit news save the south from itself, opinion: art isn’t supposed to make you comfortable, featured local savings.

Run territory assignment rules when you edit an Account

The administrator of an org with Enterprise Territory Management enabled wants territory assignment rules to run when Accounts are edited. See also : Use Rules to Assign Accounts to Territories  

There is a checkbox that can be added to the Account page layout called "Evaluate this account against territory rules on save".  To add this checkbox to the page layout, perform the following steps:

1. Setup -> Customize -> Accounts -> Page Layouts

2. Click Edit next to the page layout

3. Click the Layout Properties button at the top of the page

4. Check the "Show on edit page" checkbox next to "Evaluate this account against territory rules on save"

5. Optionally check the "Select by default" checkbox to auto-check the checkbox on the page layout

6. Click OK then save the page layout

Note :  Make sure Territory Model is Activated prior to changing the Territory Number(if Custom Territory Number field was used) for the Account Territory record to be available in Assigned Territories Related List.

The only option as of API version 21 is to use the Web Services API. See AssignmentRuleHeader in the Web Services API Developer Guide for more information:

"AssignmentRuleHeader – useDefaultRule - If true for a Case or Lead, uses the default (active) assignment rule for a Case or Lead. If specified, do not specify an assignmentRuleId. If true for an Account, all territory assignment rules are applied, and if false, no territory assignment rules are applied." Note: If a territory has multiple locally-defined account assignment rules, an account is assigned to the territory only if it matches all locally-defined account assignment rules on the territory. Related Ideas Programmatic access to territory management / assignment rules

Company Logo

Cookie Consent Manager

General information, required cookies, functional cookies, advertising cookies.

We use three kinds of cookies on our websites: required, functional, and advertising. You can choose whether functional and advertising cookies apply. Click on the different cookie categories to find out more about each category and to change the default settings. Privacy Statement

Required cookies are necessary for basic website functionality. Some examples include: session cookies needed to transmit the website, authentication cookies, and security cookies.

Functional cookies enhance functions, performance, and services on the website. Some examples include: cookies used to analyze site traffic, cookies used for market research, and cookies used to display advertising that is not directed to a particular individual.

Advertising cookies track activity across websites in order to understand a viewer’s interests, and direct them specific marketing. Some examples include: cookies used for remarketing, or interest-based advertising.

Cookie List

IMAGES

  1. How to Apply Case Assignment Rules in Flow

    run assignment rules from flow

  2. How to Trigger THE Lead Assignment Rule from Flow Builder

    run assignment rules from flow

  3. Assignment Rules Run/Re-Run by Flow

    run assignment rules from flow

  4. Running Lead Assignment Rules From Salesforce Flow

    run assignment rules from flow

  5. Running Lead Assignment Rules From Salesforce Flow

    run assignment rules from flow

  6. Running Lead Assignment Rules From Salesforce Flow

    run assignment rules from flow

VIDEO

  1. Rules flow

  2. poor siting run Adams run assignment for school

  3. sugma rules flow me

  4. IICS

  5. Pega PRPC Security

  6. Data Analytics for Manufacturing Won't Scale Without these Three Fundamental Elements

COMMENTS

  1. Running Lead Assignment Rules From Salesforce Flow

    Click Setup. In the Quick Find box, type Lead Assignment Rules. Click on the Lead Assignment Rules | New button. Now create an assignment rule, as shown in the following screenshot: Step 2: Create an Apex class and Test class. Now, we have to understand a new Apex annotation i.e. @InvocableMethod.

  2. How to Apply Case Assignment Rules in Flow

    1- Install the action using the installation links below. 2- Add a new action to your flow and search for "Apply Case Assignment Rules", this is the name of the action that you installed. 3- Give a name to the action and provide the id of the case record that you want to assign. You can use this action in any flow type that supports the action ...

  3. How to Trigger THE Lead Assignment Rule from Flow Builder

    Want to learn more about salesforce join me at https://sfdcpanther.com Hello #Trailblazers,In this video, we will talk about how to trigger the lead assignme...

  4. How To Trigger Assignment Rules In Flow

    This article explains how to trigger Assignment Rules on Salesforce while creating a Case or Lead record in a Mule Flow. Steps As per the document SOAP API Developer Guide - AssignmentRuleHeader and Salesforce Operations a header AssignmentRuleHeader needs to be set while creating a Case or Lead record.

  5. How to Re-run Salesforce Lead Assignment Rules: Flows & Apex

    1) Create a new Flow by searching for Flows under Setup and clicking the New Flow button in the top right. This example is for a Record-Triggered Flow, but you can design it a number of ways. 2) Select the Lead object for your Flow and configure the trigger for when a record is created or edited.

  6. Salesforce Lead Assignment Rules Best Practices and Tricks

    Here's a quick example: Criteria #1: If State = California, assign to Stacy. Criteria #2: If Country = United Kingdom, assign to Ben. Criteria #3: If Country = France, assign to Lucy. Criteria #4: If Annual Revenue is greater than $500,000,000 USD, assign to "High Roller Queue".

  7. Set Up Assignment Rules

    Run a Bulk Macro on Multiple Records. Create a Macro. In Lightning Experience. Add Logic to Macros. In Salesforce Classic. Tips for Creating Macros. ... Create Channel-Object Linking Rules with a Guided Setup Flow (Beta) Add Channel-Object Linking Rules for Voice Calls (Beta) Agent Experience for Channel-Object Linking (Beta)

  8. Run Case Assignment Rule from Apex

    The problem arises when your app needs to insert the Case from Apex and wants to trigger assignment rules. Using this script, a Case will be inserted but assignment rules will not be triggered as there is no such field "Assign using active assignment rules" on Case. //Instance of case. Case newCase = new Case(Status = 'New') ; //Inserting a Case.

  9. What is Lead Routing, and How to Use Assignment Rules in Salesforce

    Also known as lead assignment, lead routing is an automated process of distributing inbound leads to the department or sales rep best-equipped to handle that lead. More sophisticated lead routing systems take in consideration a variety of lead assignment rules determined by the company. Normally these rules are based on the sales territory, industry, potential deal size among other variables.

  10. What Are Lead Assignment Rules in Salesforce?

    In the Run this rule if the dropdown box, select either "criteria are met" or "formula evaluates to true. ... LeanData's lead routing flow and assignment solution is a native Salesforce application that allows users to create flows in an easy-to-understand visual graph. Its visible representation of an organization's desired lead flow ...

  11. How do I run the default Lead assignment rules on a Lead trigger

    for (Lead l:Trigger.new){lc.set(l);} And here's the usual run lead assignment code. AssignmentRule AR = new AssignmentRule(); AR = [select id from AssignmentRule where SobjectType = 'Lead' and Active = true limit 1]; //Creating the DMLOptions for "Assign using active assignment rules" checkbox.

  12. Getting Started With Assignment Flows

    To name your flow, open it from the Assignment Flow Manager and edit the name. After saving your changes, the flow name will be updated in the Assignment Flow Manager. Activating your flow To begin using your flow, set it to Active by checking the box. Once the flow is activated, your rules will be run on all records processed by Complete.

  13. Case Assignment Rules ...

    Sooooooooo - Case Assignment Rules (I'll abbreviate this to CAR) don't actually trigger automatically and never do. To trigger an assignment rule, a user must ALWAYS select "assign using active CAR". The thing is, you can both hide this checkbox, and set it to TRUE by default. So the user thinks they saved a case, but in effect they used a CAR ...

  14. Understanding Assignment Rules: A Comprehensive Guide

    Assignment rules are a set of criteria that are defined by businesses to determine how records should be assigned to users or teams within the Salesforce system. These criteria can be based on several factors, such as the record type, location, record status, or the user's role or territory. For example, a company may set up an assignment rule ...

  15. Set the option 'Assign using active assignment rules' to true, only

    7. Click the 'Layout Properties' button on the palette and disable the 'Show on edit page' and 'Select by default' Case Assignment Check-box and click OK, then click Save. 4. Test and confirm that when a user creates a new case/lead, the 'Assign using active assignment rules' checkbox is set to true. Save the case/lead.

  16. How to Re-run Salesforce Lead Assignment Rules

    Re-Run Salesforce Lead Assignments. There are times where you want to re-run assignment rules automatically under certain conditions. For example, you may assign Leads under a certain Lead Score to a Queue. When the Lead Score increases over the threshold, you then want to re-run assignment rules to assign to an inside sales rep for follow up.

  17. How Account Assignment Rules Work

    Account assignment rules now reflect Agriculture. Territory C has two rules. If you assign an account that matches all of territory A's and territory C's rules but only one of territory B's rules, the account is assigned to territory C. However, if territory B's rules are marked "Apply to child territories," the account is assigned ...

  18. Re-running Lead Assignment Rules

    I'm trying to run lead assignment rules from an invocable method, but it doesn't seem to be actually updating the lead assignment according to the rules (or at all!) We have a process by which users can create a new lead from a support case, using a quick action (where the use assignment rules checkbox isn't available). When the lead is ...

  19. Utah school removes class assignment on 'It Is So Hard to Be Trans' essay

    "The assignment was to review the writing, not the subject." Sen. Dan McCay, R-Riverton, weighed in on X , formerly Twitter, arguing that he didn't see how the essay would "fit into any ...

  20. Flow Element: Assignment

    At run time, the variable assignments occur in the order you specify. Variable whose value you want to change. Select an existing variable, or create a one. The available operators depend on the data type selected for Variable. Variable and Value in the same row must have compatible data types. Example Change the value of a customer's credit ...

  21. Run territory assignment rules when you edit an Account

    To add this checkbox to the page layout, perform the following steps: 1. Setup -> Customize -> Accounts -> Page Layouts. 2. Click Edit next to the page layout. 3. Click the Layout Properties button at the top of the page. 4. Check the "Show on edit page" checkbox next to "Evaluate this account against territory rules on save".