A Word content command that replaces the contents of its content control with text. This command should be placed into a content control already containing text, such as the Rich text content control.
The resolved value of the first attribute value
defines the text. It may be a HTML value, a Map, a Data item, a File, a String or any other kind of value that then gets converted into a String.
This command has a priority of 15.
Syntax:
out(value,format,parser,color)
With required attributes only:
out(value)
#1 - value | ||
---|---|---|
Required |
Value type |
EL-evaluated |
Yes | Boolean | Yes |
Defines the text content brought into the content control. The resolved value may be of any kind, with special handling for certain value types as described in the documentation above. |
#2 - format | ||
---|---|---|
Required |
Value type |
EL-evaluated |
No | String | No |
Specifies a Format that takes the value to output and formats it into a String as according to its formatting rules. This attribute doesn't have any effect if the output value is a HTML value or a File. The resolved String is expected to the name of a Format defined earlier in the logic. |
#3 - parser | ||
---|---|---|
Required |
Value type |
EL-evaluated |
No | String | No |
If the resolved value of this attribute is the name of a Parser, the value to output is first converted into a String (if it isn't one already) and then parsed into another type of value by the Parser. This attribute doesn't have any effect if the output value is a HTML value or a File. If both parser and format attributes are defined, the parsing process is done before the formatting.If undefined or if the named Parser cannot be found, the value retains its original type. |
#4 - color | ||
---|---|---|
Required |
Value type |
EL-evaluated |
No | String | Yes |
Defines a new color for the text brought into the content control. If not defined, the color of the content control's text is not changed. |
In its basic use out
only requires its first attribute value
to be defined.
out(greeting)
out(opportunity.Amount)
The second attribute format
typically comes useful with Number and Currency values. The third attribute parser
is generally of limited use, primarily allowing String values representing numbers to be affected by Number formatters.
out(opportunity.Amount,amountFormatter)
out(numberlikeString,fancyNumberFormat,numberParser)
Use the fourth attribute color
to dynamically alter the text color.
out(greeting,,,coolColor)
A shortcut alternative to using Content Control Properties and out
content command is using inline expression straight inside the document text. Instead of creating a placeholder text and adding a content control with out
command to it:
we can also type the inline expression straight in the text in the form of ${var.fieldName}
Inline expressions can only be used when the out
content command only needs the required attribute (out(value)
).