function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Arvind1Arvind1 

Check if "Assign using active assignment rules" is checked or not while creating Case

Hi,

 

I have a number field on Case called "No_Case_owner_changes__c" which has a default value of 0.

 

When the Case is created, I have to set the value of the above field to 1 if the "Assign using active assignment rules" is unchecked.

 

But if the "Assign using active assignment rules" is not checked when the case is created, the value of the field should remain 0.

 

So, I wanted to know is there any way I can check if "Assign using active assignment rules" is checked or not in a Case trigger.

 

Any suggestion will be helpful

 

Thanks

Arvind

 

bob_buzzardbob_buzzard

Unfortunately I don't think you'll be able to do this.  I can't find any reference to this checkbox in the schema, and checking the web services API, the use of assignment rules is controlled by an assignment rule header rather than any information on the case record itself.  Its tricky to know what to suggest in this case - presumably you are using the standard create page so that rules out taking action at that point.  I guess you could check if the case is owner by the currently logged in user and take some action if that is true or not, but that may not work for you in all situations.