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
Cuemaster98Cuemaster98 

Date dependency

I have 2 fields in my account table:

 

Site Inspection and Site Inspection Date

 

The Site Inspection field is a mandatory picklist with Yes or No as options.

 

The Date field is set up as Read only with date variables allowed.

 

I would like the following configured:

 

1> If the user selects No, the record is saved as is (date field is blank).

2> If the user selects Yes, the Date field is automatically updated with Today() and the record is saved.

 

I just inherited this SF.com stuff from a previous staff member and am trying to ramp myself up...thanks!

SAKOSAKO

Hi there,

 

You have to create a workflow:

 

1. Create/Workflows/Workflow Rules/New

 

Choose Every time a record is created or updated

Criteria would be "Site Inspection" equals Yes

 

2. Then create an action

New Field Update

Choose Site Inspection date

Formula would be "Today()"

 

Save.

 

That should work.

CaptainObviousCaptainObvious
In addition to Site Inspection equals Yes, I would add Site Inspection Date equals null to the criteria in the above workflow. Otherwise, the Site Inspection Date will be updated if you edit another field at a later date.
Cuemaster98Cuemaster98
I guess I forgot to mention that we are running the Professional version, and not the Enterprise one.  I don't have the option to create a workflow.