+ Start a Discussion
iGrafxAdminiGrafxAdmin 

Recommended way to update field based on who edited object

I need to come up with a solution that allows a certain checkbox field on a lead to be checked only if a certain user (or, ideally, members of a certain Role) change the lead status to a certain value and save the lead.  If others update the lead and chance the lead status to that same value, the checkbox should stay unchecked.  Is there a straightforward way to do this or would it involve a trigger (or something similar).  I've only worked with worklows right now.  We do have other active workflows that currently do things with this certain lead status (mainly, changing the lead life cycle based on what lead status it goes into) so I need to make sure this new solution doesn't interfere with the existing workflows.

 

Any help would be greatly appreciated!

 

Best Answer chosen by Admin (Salesforce Developers) 
Vinita_SFDCVinita_SFDC

Hi,

 

It can be done with workflows and validation rules. Create a wf with entry criteria: User:role= 'something' or may be with profile ID and Lead status = 'something'

 

then in wf action setup a field update for all the checkboxes to true that is checked.

 

Now create a validation rule on the fields to be checked by some specific user with specific lead status on record, f not then it will show an error message.

 

That is the possible way without programming, off course if you write code then it will give you more flexibility.

 

 

All Answers

Vinita_SFDCVinita_SFDC

Hi,

 

It can be done with workflows and validation rules. Create a wf with entry criteria: User:role= 'something' or may be with profile ID and Lead status = 'something'

 

then in wf action setup a field update for all the checkboxes to true that is checked.

 

Now create a validation rule on the fields to be checked by some specific user with specific lead status on record, f not then it will show an error message.

 

That is the possible way without programming, off course if you write code then it will give you more flexibility.

 

 

This was selected as the best answer
iGrafxAdminiGrafxAdmin

Thanks!  That was very helpful!