Share via


Product configurator, new expression editor

In Cumulative Update 6 for Dynamics AX 2012 R2 we have included a new expression editor for
the Product configurator. You can use the editor to create expression Constraints,
Conditions and Calculations. (Calculations is a new concept, which was
introduced in Cumulative Update 6, and was described in a previous post in this
blog).

The screenshot below shows the expression editor as it will appear when you click
the drop down for the expression column for a new Constraint or a new Condition.

 Constraint expression editor 

The editor has a text field, in which you can type an expression, and a tabular list
section in the lower part of the form. The tabs in the list represents the
elements or symbols you can include in an expression Constraint. They are:

  • Attributes
  • Operators
  • Values (attribute values)

The All symbols tab displays all entries from the three other tabs (a combined list).
The items that appear in the list are filtered depending on the user input in
the Expression field. In the example below, the user has started writing an Implies constraint (“im”). The only two
matches are the Implies and the Times operators, and thus they
are the only symbols remaining in the list.
 

You can add operators, attributes or values to an expression by typing, or by selecting an
element in the list with the mouse (double-click, press the Enter key or use
the Insert symbolaction in the list action pane to insert the symbol). You can also
press Alt + Arrow down to set focus on the grid, then use arrow keys to move in
the lists and then press Alt + I to insert symbols from the grid. If you move
the cursor in the expression field, you can press F5 to refresh the lists in
the symbol grid.

The editor attempts to validate the syntax as you build an expression. If you type in an
unknown text and hit the space bar, an error is displayed. Below is an example
where the user typed in “XYZ”.

You can also use the Validate action to validate the syntax at any point.

 Calculation expression editor

When the expression editor is used for Calculations, there are more operators available and you can
include attributes of any type except free text. The screenshot shows the available
operators if you type “s” in the Expression field.