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
Jennifer DobosJennifer Dobos 

Need help with creating a formula

I'm trying to write a formla for a text field.  We have a "Communication Preference Confirmed" text field that I would like to show "Recieved" if the "Communication Opt In " check box = True OR if the Email Opt Out = True

ALSO

We would also like the "Communication Preference Confirmed" text field to show "Required" if the "Communication Opt in"  checkbox is blank and the "Email Opt Out" = False

Thanks!
Best Answer chosen by Jennifer Dobos
AgiAgi
Hi,

IF( OR(  Communication_Opt_In__c = True,  Email_Opt_Out__c = True),  "Received",
If( AND( Communication_Opt_In__c = False,  Email_Opt_Out__c = False), "Required", null))

All Answers

Hd037Hd037

hello you can use this type of formula 

IF( Communication Opt in == false && Email Opt Out == false, 'Required', 'Recieved')

thanks 

MoggyMoggy
HI hd, Jennifer requested "check box = True OR if the Email Opt Out = True"

therefore the formula should be
IF( Communication_Opt_in__c == true || HasOptedOutOfEmail == true, 'Received', null)

I assume in there that your custom field "Communication Opt in" has the same field name as you labeled it. Otherwise you will need
to use your API name in that formula ( click insert field in the formula and simply select that one)

You can also replace null with any text value if you want to show anything if both values are false
AgiAgi
Hi,

IF( OR(  Communication_Opt_In__c = True,  Email_Opt_Out__c = True),  "Received",
If( AND( Communication_Opt_In__c = False,  Email_Opt_Out__c = False), "Required", null))
This was selected as the best answer
phiberoptikphiberoptik
@Jennifer - please try one of these out, validate it, and mark it as the answer so this can be solved. Thanks!
Jennifer DobosJennifer Dobos
Thanks for your help everyone!