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

Reference Custom Labels in Sharing rule crieria


I have to create a crieria based sharing rule for Account and I was trying to referance a custom label in one of the filer.Unfortunately it is not working . Does any know,is there any way to referance a custom label in sharing rule filter ?

Advanz Knowledge SystemsAdvanz Knowledge Systems



Hope it is helpful for you



Represents a criteria-based sharing rule for custom objects. It extends the CriteriaBasedSharingRule metadata type and inherits its criteriaItems field.

CustomObjectCriteriaBasedSharingRule is used by the criteriaBasedRules field in CustomObjectSharingRules.
Field     Field Type     Description
accessLevel     string     Required. A value that represents the type of sharing being allowed. The possible values are:


booleanFilter     string     Represents the filter logic of the sharing rule.
name     string     Required. Name for the sharing rule. Corresponds to Label in the user interface.


Check in this link


There should not be any reference of custom label in sharing rule.