Conditional Logic Structure
Basic Model
<!--RENDER='<merge field>' == '[Value]' -->
[Conditional Content]
<!--ENDRENDER-->Complex Model
<!--RENDER='<merge field>' == '[Value]' -->
This message is for an active account.
<!--RENDER1=( ('<merge field>' == '[Value]' || '<merge field>' == '[Value]')
&& ('<merge field>' == '[Value]' || '<merge field>' CONTAINS '[Value]') ) -->
Special terms apply for your account based on location and contract status.
<!--RENDER2= <merge field> <= [Value] -->
Note: This opportunity is marked as urgent. Immediate action is recommended.
<!--ENDRENDER2-->
<!--RENDER2='<merge field>' != '[Value]' -->
Dear Manager, we have tailored recommendations for your review.
<!--ENDRENDER2-->
<!--ENDRENDER1-->
<!--ENDRENDER-->1. <!--RENDER='<merge field>' == '[Value]'-->
Purpose
Start of a conditional block. S-Docs evaluates the expression and only renders the block if the condition is true.
2. [Conditional Content]
Purpose
Text or sections that are included in the generated document only when the render condition evaluates to true.
3. <!--ENDRENDER-->
Purpose
Closes a RENDER block. It must match every RENDER tag.
5. ==, !=, >, <, >=, <=, CONTAINS, NOT CONTAINS
Purpose
Comparison operators inside render conditions.
==
Equal
!=
Not equal
>
Greater than
<
Less than
>=
Greater than or equal
<=
Less than or equal
CONTAINS
String contains substring
NOT CONTAINS
String does not contain substring
7. &&, ||, ()
Purpose
Used for combining multiple conditions into one render statement.
&&— AND (both conditions must be true)||— OR (either condition can be true)()— Used to group multiple expressions
6. RENDER1, RENDER2, RENDER3
Purpose
Nesting multiple conditions under one condition. Each nested level must have an incremented name (e.g., RENDER1, RENDER2) and be paired with a matching ENDRENDER1, ENDRENDER2, etc.
Summary Table
RENDER Tag
<!--RENDER='<merge field>' == '[Value]' -->
Starts a conditional block. S-Docs evaluates the expression and renders the block only if the condition evaluates to true.
Conditional Content
[Conditional Content]
Text or sections included in the generated document only when the render condition evaluates to true.
ENDRENDER Tag
<!--ENDRENDER-->
Closes a RENDER block. Every RENDER must have a matching ENDRENDER.
Nested RENDER Tags
RENDER1, RENDER2, RENDER3
ENDRENDER1, ENDRENDER2
Used for nested conditional logic inside a parent RENDER block. Each level represents a deeper condition.
Comparison Operators
==, !=, >, <, >=, <=
Compare values in render conditions (equality, inequality, numeric comparisons).
Substring Operators
CONTAINS, NOT CONTAINS
Evaluate whether a string contains (or does not contain) a specified substring.
Logical Operators
&&, |
Combines multiple conditions.
Parentheses
( )
Groups multiple expressions to control evaluation order in complex conditions.
Full Example
Last updated
Was this helpful?

