Editing Conditional Element

The conditions of the elements are specified using the Conditions table which has two columns – “Condition” and “Element”. To set the conditions identifying when the element is going to be printed specify the condition directly into the “Condition” column. To set the properties of the element that will be printed when the condition holds click on the “Set Report Element” button to bring up the “Report Element” dialog. In this dialog select the type of the element to be printed and then specify its properties.

As an example let us assume that we are designing a presentation of an Account business object and we want to show the account balance in green if it is greater than 100 and in red if it is less than 100. To do this we need to define a conditional element. The condition table of this element will define two elements – both elements will be tag elements containing the Account.Balance expression. We will set the foreground color of the first tag element to be green and the second one – to be red. In the condition cell of the first element we will specify the following expression: Account.Balance >= 100 and in the condition cell of the second element we will specify Account.Balance < 100.

Tick this box if you want to collapse the element if nothing is printed. It is possible that after evaluating conditions of a conditional element at run time no element is printed into the document at all. In this case the area occupied by the conditional element can be left blank (if the checkbox is not ticked) or it can collapse and leave the space for other elements.

See also the Attach Conditions command in the Miscellaneous Commands section.

  • Last modified: 2022/12/14 07:28