Use Case:
Users may want a colored field to appear on a transaction only when specific conditions are met.
This can be done by using two custom transaction body fields: one for the colored text and one for the condition.
How It Works:
A. Create the first custom transaction body field:
- Navigate to Customization > Lists, Records, & Fields > Transaction Body Fields > New
- Enter the following:
- Label: Colored Field
- ID: _coloredfield
- Type: Inline HTML
3. Click the Applies To tab:
4. Click the Display tab:
5. Click the Validation & Defaulting tab:
- Formula: Leave unchecked
- Default Value:
<font size=6 color=red><b>Sample Text</b></font>
6. Click Save
B. Create the second custom transaction body field:
1. Navigate to Customization > Lists, Records, & Fields > Transaction Body Fields > New
2. Enter the following:
- Label: Past Due
- ID: _pastdue
- Type: Free-Form Text
- Store Value: Uncheck
3. Click the Applies To tab:
4. Click the Display tab:
5. Click the Validation & Defaulting tab:
- Formula: Check the box
- Default Value:
CASE WHEN {duedate} < {today} THEN {custbody__coloredfield} ELSE ' ' END
6. Click Save
Note:
Inline HTML fields cannot be hidden at the field level because they display as Inline Text. If needed, hide the field on the form instead.