Cert++
Close

Conditionally required fields with validation rules

Key Takeaway

Write the validation rule formula to describe the invalid state: the condition is true AND the required field is blank.

A conditionally required field is a field users must fill in only when some other condition is true, such as a Close Reason when an opportunity is Closed Lost. An app builder sets this up with a validation rule. The rule's formula checks the data before the user can save the record.

The formula describes the invalid state

A validation rule formula describes the invalid state, not the valid one. When the formula returns True, the user sees the error message and can't save the record. When it returns False, the save goes ahead.

Write the error condition as a plain Boolean expression. CloseDate < TODAY() is the correct form, and IF(CloseDate < TODAY(), TRUE, FALSE) is the incorrect form.

Platform App Builder Study Guide

Checklist progress

0/340Learned

Given a scenario, demonstrate the use of validation rules to meet stated business requirements

0/15

Prepare for the Exam

Play Today's Certle

Study Community

Ask questions and get the latest info from other Platform App Builder studiers.