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
SFDC palaceSFDC palace 

Validation Rule

Hi,  
 
Trying to set up a Validation Rule on Leads, and cannot get this one to work,  can anyone see an error.   If bolean = True, and Sales Type = Field Sale, then error if Sales Visit date = NULL, for Record type.
 
Any help would be really appreciated.
 
Thank you
 
AND  (
  (Convert_this_Lead__c = TRUE),
  ISPICKVALUE(Sale_Type__c ,"Field Sale"),
     ISNULL(Initial_Sales_Visit_Date__c ),
$RecordType.Name = "EUR:Pickfords Business Moving")
SFDC palaceSFDC palace
Anyone know how to to turn off the Smilies !!!
SKerrSKerr

Hard to tell with the smilies, but try removing the "=TRUE"

Sometimes a field is, in itself, either true or false and doesn't need to be checked - it's redundant.

EricBEricB
To turn off smilies, when entering your formula, try putting it inside a SRC block (see the 5th button from the left on the editing toolbar)
SFDC palaceSFDC palace
Code:
AND( 
(ISPICKVAL(Sale_Type__c, "Field Sale")), 
ISNULL( Initial_Sales_Visit_Date__c ), 
Convert_this_Lead__c , 
$RecordType.Name = "EUR:Pickfords Business Moving")

 
Thanks for you help, above is the correct formula,  Interesting that you do not have to give a value for a bolean field.   I could not find this in any help screen, a source at SFDC even said to use 1 or 0.
 
 
SFDC palaceSFDC palace
Above I discovered how to deal with Bolean fields when its selected, now I want to use one for not selected.
 
I have tried ISNULL(Convert_this_Lead__c), and below tried NOT(Convert_this_Lead__c)
 
Code:
AND( 
(ISPICKVAL(LeadStatus__c ,"S - Qualified")), 
NOT(Convert_this_Lead__c), 
$RecordType.Name = "NA:Marketing")

 
any help woudl be appreciated, not sure why this does not work...
 
Thanks
SFDC palaceSFDC palace
I have found the error....   simple field description...!!!  NOT function works fine.