Show/Hide Toolbars

 PhraseExpander 5 Manual

Navigation: Designing templates > Macros > Data

Calculate expression

Scroll Prev Top Next More

It calculates a math expression. You can define the number of decimal digits to display and the decimal separator.

Check the list of supported operators.

 

The macro can be used to calculate the time difference (in minutes) between to times. This can useful, for example, to capture the duration of a visit by capturing both the start time and the end time.

 

Syntax

{#calc expression -[decimal=.][round=5][thousands=,]#}

expression: math expression to compute

[decimal]: it specifies the custom decimal separator

[round]: it specifies how many digits should be used for rounding

[thousands]: it specifies the custom thousands separator

 

Example

Template:

{#calc (9+2)*100-7#}

 

Result:

1,093

 

 

Template:

{#calc 1:00pm - 1:45pm#}

 

Result:

45

Created with Help & Manual 7 and styled with Premium Pack Version 3 © by EC Software