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
sami amisami ami 

Checkbox formula field

Hi,

 

I want to make a checkbox true if my contact time zone is between something.

So i created a timezone field (formula field to set time zone based on State) on my contact and specified some timeranges in my custm setting.So i made custom list variable.

Now i want to make my checkbox true if my contact.timezone is between my global list timezone.range1 and range2

I am not understanding how to write formula for this.Any help??

 

Thanks in advance.!!

digamber.prasaddigamber.prasad

Hi,

 

You cann't access custom settings in standard validation rules. To have this validation, you will need to write trigger.

 

Please let me know if you have any question around trigger.

 

Happy to help you!

 

Regards,

Digamber Prasad

Hari SharmaHari Sharma

The hierarchical custom settings can be accessed in formula fields. Sample code provided below...

 

IF(innovateforce__NumberofLocations__c > $Setup.innovateforce__TimeZone__c.innovateforce__Range__c, true, false)

 

So, if your custom setting type is Hierarchy, then this could be the solution.  

 

Regards,

Hari Sharma

 

 

sami amisami ami
But if i use trigger,it wont change dynamically based on time of caller.Correct???
It will be fired only when record is created.
sami amisami ami
My custom setting is LIST sir..
Even if i use Hierarachial,How can i spciify range??
My callers will be in Central time zone..So i should show only lead records who are in working zone to my sales persons.any idea on how can i get this??

digamber.prasaddigamber.prasad

Hi,

 

Apart from Insert, you can fire your trigger on Update & Detele events too.

 

Let me know if you have any specific question around it.

 

Happy to help you!