You need to sign in to do that
Don't have an account?

cehckbox field mandatory when the status changes
Hello,
How to make checkbox field mandatory when ever the status changes.
i have written sample validation rule
IF(AND(
ISPICKVAL(Status,"Open"), ISPICKVAL(PRIORVALUE(Status),"Closed"),
(Flag__c = True)))
Thanks
How to make checkbox field mandatory when ever the status changes.
i have written sample validation rule
IF(AND(
ISPICKVAL(Status,"Open"), ISPICKVAL(PRIORVALUE(Status),"Closed"),
(Flag__c = True)))
Thanks
Use Error Condition Formula as following And give a apriprote error message like 'Flag should be set before changing status'.
Let me know if any problem you are facing after that. Otherwise mark it as answer so that other will get help from this.
Thanks
Banwari
All Answers
Use Error Condition Formula as following And give a apriprote error message like 'Flag should be set before changing status'.
Let me know if any problem you are facing after that. Otherwise mark it as answer so that other will get help from this.
Thanks
Banwari
im checking status changes only from closed to open then only the flag should be checked.
How can i achieve this.
Thanks
you can achieve your requirement by following error condition:
Flease check the case of Status field values. wether Open or open and Closed or closed.
Thanks
Banwari
Its working but,
Once the flag is checked and saved, immediatley this flag should get unchecked(after saving record).
How to do this?
Thanks
If you want to achive this you can use following trigger and delete validation rule which is made previously. let me know if any problem you are facving after that.
Thanks
Banwari
Im getting below error
Error: Compile Error: Comparison arguments must be compatible types:
Try following code.. let me know if any problem you are facing after that otherwise mark it as answer.
Thanks
Banwari
there should be small correction
objRec.Flag__c = true; should be true // in the line number 4
but the problem is once the record is saved the Flag check box should automatically uncheck but its not happening.
You would rather not modify len no 4. It must be objRec.Flag__c = false to automatically uncheck. Please revert your change at line no. 4.
Thanks
Banwari
If i change that then it not allowing me to save the changes, it keeps on throwing an error.
Thanks
use following code:
Now it will not through error.
Thanks
Banwari
Still no luck, even if i check the flag its not allowing me to proceed.
Thanks
Try following:
It will work.
Thanks
Banwari
it seems not working,
i was thinking to use workflow
AND( ISPICKVAL(Case_Category__c,'Defect'), ISPICKVAL(Case_Re_opened_By__c,'CS'),TEXT(Status) = 'New' ,TEXT(PRIORVALUE(Status)) = 'Closed', NOT(Flag__c =False))
and field update
clear checkbox field
New Field Value = False
but the formula is throwing an error
Why are you using workflow. please inactive it.
Thanks
Banwari