+ Start a Discussion
satakshisatakshi 

Account Validation Rule

Hello,
I want validation rule on account object. Its a professional edition. When lead converts into account I am checking Client__c field.
I want validation rule on account so that if that account is created by lead conversion and client is equal to true then account address is manadatory. I am getting validation error on lead conversion page rather than account page.

AND( ISBLANK(BillingAddress), NOT(ISNEW()), Client__c  = TRUE)
Waqar Hussain SFWaqar Hussain SF
Create a checkbox field on lead object and Account object. And on lead field set default value of this checkbox field to checked. And set the default value of account checkbox field to unchecked.

Let call it Created_From_Lead__c field on lead and on account. Then map this lead field to account field. 

Now put validation rule on account as 
​AND( ISBLANK(BillingAddress), NOT(ISNEW()), Client__c  = TRUE, Created_From_Lead__c = TRUE)

 
satakshisatakshi
Thanks for replying. I have tried this but still receiving an error.
kamala swarnalathakamala swarnalatha
Hi,

Will you change code like this

AND( ISBLANK(BillingAddress), ISNEW(), Client__c  = TRUE, Created_From_Lead__c = TRUE) in validation rule on account object.

I hope this work for your requirement.

Thanks,
Kamala
Sweet Potato Tec.
satakshisatakshi
Hi Kamala,

I did this but it doesnt work for me
kamala swarnalathakamala swarnalatha
Hi,

Try this one

AND( ISBLANK(BillingAddress),Created_From_Lead__c = TRUE) 

Thanks,
Kamala
Sweet Potato Tec.