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
Naveen KvpNaveen Kvp 

I have a two fields in Tax master object Excise Duty % and Service Tax % how to write a validation for Only one of the two to be entered.

I have a two fields in Tax master object Excise_Duty__c and Sales_Tax__c  how to write a validation for Only one of the two to be entered.

      i am wrote a formula like this:

OR(
NOT( ISBLANK( Excise_Duty__c ) ),
ISBLANK( Sales_Tax__c )  
)

This is working for only one field for checking condition,how can i check for both fields!
Please provoide me profer solution for this!! Thanks in advance 
Naveen KvpNaveen Kvp
AND (
OR(NOT(ISBLANK(Excise_Duty__c ) ),
ISBLANK(Service_Tax__c )),
OR(
NOT(ISBLANK( Service_Tax__c ) ),
ISBLANK(Excise_Duty__c ) 
))

This will work fine i got solution cool guys :)
 
Mudasir WaniMudasir Wani
Hi Naveen,

Use of  AND operation will do it
AND( ISBLANK( Excise_Duty__c  ),
ISBLANK( Sales_Tax__c )  
)

Please mark this as solution if this solves your problem, So that if anyone has this issue this post can help