X-ERP Help

09. Data fields and expression editor

Expressions connect data fields, parameters, functions and conditions to dynamic content without changing the X-ERP source code.

Data fields and expression editor

Expressions connect data fields, parameters, functions and conditions to dynamic content without changing the X-ERP source code.

Open Report designer on the desktop Administration.

Your goal

You can bind a field, open the expression editor and build simple text, arithmetic and conditional expressions in an understandable way.

Why this is crucial in the report designer

Expressions make a template intelligent: Headings react to parameters, texts are made up of several fields and elements only appear when appropriate.

Elements and settings at a glance

  • f mark: Shows that a property can be controlled by an expression; an active marker indicates a set expression.
  • Fields: Data values from the current data source, usually referenced in square brackets.
  • Parameters: Values provided externally or in the report, such as time period or record ID.
  • Features: Text, date, mathematical, logical and summary functions.
  • Operators: Calculating, comparing and logical connections.
  • Constants: Fixed text, numbers, true/false or zero values.
  • Syntax check: Highlights errors and provides assistance with available functions and fields.

Here's how to do it

  1. Select a label and open the f-marker or the expression editor for the desired property.
  2. Insert an available field from the list instead of guessing the name.
  3. Expand the expression gradually, for example to [Menge] * [Preis].
  4. Use conditions only as complex as necessary and document unusual logic in the element name.
  5. Confirm the printout and check several data variants in the preview.

Exercise

Create three test fields: a direct bound value, a quantity times price calculation, and a conditional hint with Iif(...). You choose the actual field names from your X-ERP field list.

Check the result

  • The expression contains only available fields and parameters.
  • Data types match the operation.
  • Empty values do not lead to errors or misleading text.
  • The result is true for positive, negative and zero values.

Typical errors and their solutions

  • Enter field name: Even small deviations lead to invalid expressions; choose from the list.
  • Copy logic into many elements: If reused, use a calculated field.
  • Force display format in expression: For numbers and dates, preferably use Text Format String.

Your result

They allow reports to react to data while keeping the logic understandable and maintainable.

Further information / source

Related topics

  1. For customizers – customize screens and forms › Report designer › 10. Calculated fields, totals and running values
  2. For customizers – customize screens and forms › Report designer › 11. Format numbers, dates and text
  3. For customizers – customize screens and forms › Report designer › 13. Parameters and filters

Frequently asked questions

What can I implement myself according to this page?

You can bind a field, open the expression editor and build simple text, arithmetic and conditional expressions in an understandable way.

How do I recognize a shareable result?

The expression contains only available fields and parameters. Data types match the operation. Empty values ​​do not lead to errors or misleading text. The result is true for positive, negative and zero values.