 • Stephen02
• NEWBIE
• 50 Points
• Member since 2016

• Chatter
Feed
• 0
• 0
• 0
Likes Given
• 8
Questions
• 7
Replies
Hi - I have a need for a formula with multiple OR conditions in a Workflow rule

For example,
IF (Preferred_Language__c does NOT equal English, or Spanish, or French, or Mandarin
THEN
(update field called Let_Template to English)

Thank you.

• • May 10, 2016
• Like
• 0
Trying to determine a more efficient way to write the below formula.  Basically it evaluates the current day of the week, and if Monday - Thursday (e.g. 1-4)  and it's before 1PM then return Today, else return Today + 1. IF the day is Friday before 1PM then return Today, else Today + 3. If Saturday (6), return Today + 2. If Sunday (7), return today +2

IF(
OR(CM_Test_Date_Field__c = "1",CM_Test_Date_Field__c = "2",CM_Test_Date_Field__c = "3",CM_Test_Date_Field__c = "4",CM_Test_Date_Field__c = "7"),

• • May 10, 2016
• Like
• 0
My org and all user locales are Eastern Standard Time. The formula below essentially says, if it is before 1PM, then show a date of today, but if it is after 1PM show a date of tomorrow.  Now I need to add a condition that says, if Today equals "Saturday" or "Sunday" then return a date of Monday.

• • May 06, 2016
• Like
• 0
Hi - I am wondering if anyone can assist with this formula?
Formula Requirement:

IF the current GMT time = anytime between 07:00 and 18:00 GMT, THEN return a date of today, otherwise return a date of the following day
• • May 04, 2016
• Like
• 0
Hi - I am working with the three Date formulas below (all of which do the same thing) and that is it checks to see if the current time is before 1 PM MT, and if so, then show a resulting date of today (e.g. May 3, 2016). If it is after 1 PM MT, then show a resulting date of tomorrow (e.g. May 4, 2016).  Now I have to expand the formula to be a bit more intelligent.

With that said, I have users in different locals/timezones and I am asking for a formula that calculates the following (note I do prefer Formula 3 below, but am open to whatever recommendations work for the requirement below:)

Requirements:
* IF GMT +00:00, then calculated result is today (e.g. May 3, 2016) and
* IF GMT +01:00, then result is today (e.g. May 3, 2016) and
* IF GMT +02:00, then result is today (e.g. May 3, 2016) and
* IF GMT +03:00, then result is today (e.g. May 3, 2016) and
* IF GMT +04:00, then result is today (e.g. May 3, 2016) and

* IF GMT +05:00, then result is tomorrow (e.g. May 4, 2016) and
* IF GMT +06:00, then result is tomorrow (e.g. May 4, 2016) and
* IF GMT -01:00, then result is tomorrow (e.g. May 4, 2016) and
* IF GMT -02:00, then result is tomorrow (e.g. May 4, 2016) and

These working formulas can be used for reference and/or to add on to

#1)
IF(NOW() < DATETIMEVALUE(TEXT(YEAR(TODAY()))&"-"&TEXT(MONTH(TODAY()))&"-"&TEXT(DAY(TODAY()))&" 20:00:00" ),TODAY(),TODAY() + 1)
(Note: this is converting todays year, month, and day by using the TEXT() formula type to concatinate them with a time of 2000 hours so that the DATETIMEVALUE converts the string "YYYY-MM-DD HH:MM:SS" into a DateTime. I then see if NOW is less than that time. if so return todays date, if not return todays date + 1 day.

#2)
IF( VALUE(LEFT(RIGHT(TEXT(NOW()),9),2)) < 20, TODAY(), TODAY()+1 )

#3)
IF( NOW()  <  DATETIMEVALUE(TODAY())+(20/24) , TODAY(), TODAY()+1)
(Note: Datetimevalue function returns today's date & 12 am GMT ,thus added 20 hours to it , even NOW() return current time in GMT later all these values are converted into User's locale. You can also use CreatedDate field instead of NOW() if that's what you seek.)

Thank you!
• • May 03, 2016
• Like
• 0
Hi - I am attempting to write a case field formula that will calculate the following:
I would like it to calculate the following requirements:
* IF it is after 1 PM MT, then display tomorrow's date.

Use case example:
It is 10 AM MT on May 2 2016 then it should show/calculate to May 2 2016
It is 2 PM MT on May 2 2016 then it should show/calculate to May 3 2016

Thus far I have the following, but running it tonight May 2 2016 at 8:45 PM MT, it still calculates/displays May 2 2016:
IF( VALUE(LEFT(RIGHT(TEXT(NOW()),9),2)) < 19, TODAY(), TODAY()+1 )

Thanks for the help.
• • May 03, 2016
• Like
• 0
Hello - I am attempting to enter a formula into a Salesforce Email template.
The requirement is this: If a field (e.g. Case.Send_WUPSIL_Letters__c) equals a specific value (e.g. Acknowledge), then I want to display a text message (e.g. We expect to have a response to you within the next 24 hours.

The below formula is what I have thus far, but I cannot get the text to return in the email template.

Thank you for contacting us. {! IF(Case.Send_WUPSIL_Letters__c=Acknowledge,"We expect to have a response to you within the next 24 hours")}
• • April 28, 2016
• Like
• 0
Hi - I am using Salesforce's email to case functionality  (it's on-demand) and I have a trigger that automatically creates a new Contact record (if he contact's email address is not already in the system).

What I am now trying to figure out is how to add this Contact record (created above) to a specific Account record that I call General Consumer?

Thanks.
• • April 11, 2016
• Like
• 0
Hi - I am attempting to write a case field formula that will calculate the following:
I would like it to calculate the following requirements:
* IF it is after 1 PM MT, then display tomorrow's date.

Use case example:
It is 10 AM MT on May 2 2016 then it should show/calculate to May 2 2016
It is 2 PM MT on May 2 2016 then it should show/calculate to May 3 2016

Thus far I have the following, but running it tonight May 2 2016 at 8:45 PM MT, it still calculates/displays May 2 2016:
IF( VALUE(LEFT(RIGHT(TEXT(NOW()),9),2)) < 19, TODAY(), TODAY()+1 )

Thanks for the help.
• • May 03, 2016
• Like
• 0
Hello - I am attempting to enter a formula into a Salesforce Email template.
The requirement is this: If a field (e.g. Case.Send_WUPSIL_Letters__c) equals a specific value (e.g. Acknowledge), then I want to display a text message (e.g. We expect to have a response to you within the next 24 hours.

The below formula is what I have thus far, but I cannot get the text to return in the email template.

Thank you for contacting us. {! IF(Case.Send_WUPSIL_Letters__c=Acknowledge,"We expect to have a response to you within the next 24 hours")}
• • April 28, 2016
• Like
• 0
Hi - I am using Salesforce's email to case functionality  (it's on-demand) and I have a trigger that automatically creates a new Contact record (if he contact's email address is not already in the system).

What I am now trying to figure out is how to add this Contact record (created above) to a specific Account record that I call General Consumer?

Thanks.
• • April 11, 2016
• Like
• 0