+ Start a Discussion
ErocEroc 

Task Subject Validation Rule

I need to write a Data Validation rule to enforce users to use the Task Subject pick list values when creating tasks or activities.

 

I've started with this but need some help finishing it:

 

IF( Subject  <> "Call, Contacted, Conversation, Fax, Handoff, Interview, Left Voicemail, Mailed Collateral, Other, Send Email, Send Letter, Send Quote, Web Meeting , value_if_true, value_if_false)

 

Thank you,

BrunoMBrunoM

Your formula will need to follow this pattern:

 

 OR ( Subject  <> "Call", Subject <> "Contacted" )  

Message Edited by BrunoM on 06-18-2009 03:28 PM
Message Edited by BrunoM on 06-18-2009 03:29 PM
ErocEroc

Here's what I have so far and when I activate the rule, it errors out on all Tasks I try to create, even those with the Subject chosen from the picklist.

 

OR(Subject <> "Call", Subject <> "Contacted", Subject <> "Conversation", Subject <> "Fax", Subject <> "Handoff", Subject <> "Interview", Subject <> "Left Voicemail", Subject <> "Mailed Collateral", Subject <> "Other", Subject <> "Send Email", Subject <> "Send Letter", Subject <> "Send Quote", Subject <> "Web Meeting")

BrunoMBrunoM

Sorry my mistake. It should be

 

AND ( Subject <> "Call", Subject <> "Contacted" )

 

The error logic triggers if the statement evaluates to TRUE. If it matches any of the values you define then it will evalate as FALSE and the error message won't trigger.

BrunoMBrunoM
Also note that this will be case sensitive. If a user enters a subject of "call" instead of "Call" it will trigger an error.
NPMNPM

If it is a picklist field - and you  indicated it was - you will need to use ISPICKVAL (the old way) or TEXT functions.

 

Go to the function when youare building your formula and refer to the help for usage and examples. 

 

Picklist fields are only supported in TEXT functions used in validation rule formulas, formula fields, and field updates. In other formulas, use ISPICKVAL or CASE when referencing a picklist field.

GeraldineGrayGeraldineGray

Maybe a silly question but could you not just make it required on the page layout?