The Designer integrates a powerful script language that offers users a high level of flexibility when it comes to personalizing their card layouts. Instead of assigning fixed values to layout or layout-page properties, it is possible to control their values through expressions that yield different results in different circumstances. For example, CardExchange® Producer and TrustID can inspect a field in the database and then decide to set a different background color, or even show a completely different card layout.
...
The Expressions tab of the page-setup window allows for specifying expressions for the layout condition, a number of layout-page properties and any number macro commands. The layout condition is available from the professional and Pro editions. The layout-page properties and the macro commands are only available in the Business and Pro-Smart editions.
Expressions are written in IronPython (see http://ironpython.net), which is the .NET implementation of Python, (see http://www.python.org). Since the documentation of Python is publicly available on these websites, this help file will limit itself to explaining how Python can be used within CardExchange® Producer and TrustID as well as giving some practical examples.
...
Layout conditions can be controlled by expressions that are much more complex than this. The expressions can contain functions and they can use multiple variables. It is possible to define the layout conditions in such a way, that for some records multiple layouts apply and for others no layout at all. CardExchange® Producer and TrustID will print multiple cards for the same record if multiple layouts apply. If no layouts apply, CardExchange® Producer and TrustID will skip the record when executing a print batch.
...
backgroundcolor
CardExchange® Producer and TrustID will prompt again for a default value, where you can type, for example, 'AliceBlue'. In the mappings window, the variable name will appear among the visible items and can be mapped to a database column that contains the desired color name for each record.
...
where the variable 'flag' should be mapped to a database column that can contain the values 'A' or 'B'. As a result, CardExchange® Producer and TrustID will show a red or green background if that column contains the value 'A' or 'B' respectively. the background will be blue for all other values.
...