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
jhamletjhamlet 

Relational Date Forumla

I am trying to create a field that displays a message when an account/company was created in a specific date range.
 
This seems fairly trivial, but I am having trouble with the date forumla.
 
Case (
Date_account_was_opened__c > 01/01/2008,
"Custom Text Message", NULL
)
 
How would I write an expression for >, <, !=, with date fields? I can't seem to find the correct format to use.
 
Any ideas or advice would be grately appreciated.
jhamletjhamlet
I have also tried to do this with an S-Control with no luck:
 
var alert = {! IF( Account.CreatedDate > 09-11-2008T00:00.000z, true, false)};
if  (alert) {
document.write("<font face=Arial size=-1><b>Custom Message for New Account.</b></font>");
}
else {
document.write("<font face= Arial size=-1><b>Customer Message for Older Account</b></font>");
}
</script>
 
 
JakesterJakester
Code:
if( CloseDate >date(2008,1,1),"2008","Pre-2008")

 
jhamletjhamlet
Excellent! 

Thank you for the help... I was able to get it working.