Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Insert excerpt
_Banners
_Banners
nameactionflow
nopaneltrue

This page provides details of the properties for

the  Insert excerpt_action_calculate_action_calculatenopaneltrue action node

the calculate node and associated expressions. These are part of actionflows.

Overview

Image Modified

Use a 

Insert excerpt
_action_calculate
_action_calculate
nopaneltrue

action

node to manipulate data that is passed to it. Calculate

actions Example

nodes have their own attributes, which can reference incoming data via expressions using one or more of the 115+ functions available in PhixFlow.

Live Search
spaceKey@self
additionalnone
placeholderSearch all help pages
typepage

Panel
borderColor#00374F
titleColorwhite
titleBGColor#00374F
borderStylesolid
titleSections on this page

Table of Contents
maxLevel3
indent12px
stylenone

Example

Click to play the following video that shows an example of using a calculate node in an actionflow.

View file
nameOpen Calculate Example.mp4
height250

Initially there is

The video shows  an actionflow

which

that opens a new screen containing a dynamic text field.

The aim of this example is to populate this

It then populates the dynamic text field with a message, which is set

by an attribute

in a calculate node attribute. The steps for

this

are:

Create a  Insert excerpt_action_calculate_action_calculatenopaneltrue node by dragging and dropping a node from the create section in the toolbar
  1. Drag a calculate node from the toolbar and drop it into the actionflow diagram.
  2. Name the calculate something meaningful, e.g. Set Message
  3. Disconnect the
    Insert excerpt
    _action_screen
    _action_screen
    nopaneltrue
     node from the 
    Insert excerpt
    _driving_interface_connection_point
    _driving_interface_connection_point
    nopaneltrue
    .
  4. Connect the 
    Insert excerpt
    _driving_interface_connection_point
    _driving_interface_connection_point
    nopaneltrue
    to the 
    Insert excerpt
    _action_calculate
    _action_calculate
    nopaneltrue
    node.
Connect the  Insert excerpt_action_calculate_action_calculatenopaneltrue to the  Insert excerpt_action_screen_action_screennopaneltrue node, using Create a calculate attribute
  • Name this Message
  • Add the following expression
    1. To pass data into the actionflow, go to the Inputs section on the left. Connect the component input connection point
    - 'ScreenToOpen'. This is the name of the outermost area/form on the screen, enabling data to be passed to it.
    1. ScreenToOpen to the calculate node.
    2. Click on the calculate node to open its properties.
    3. In the Attributes section, add a new calculate attribute and set:
      1. Name to Message
      2. Expression to:

        Code Block
        "You have successfully set up a calculate node" 


    4. Map the calculate attribute to the dynamic text field on the
    screen 
    1. screen as follows: 
      1. Right-click on the connection and click Configure Mappings.

      2. Drag the Message attribute from the calculate
    (LHS)
      1. node, on the left, to the Message attribute on the open screen
    (RHS)
      1. , on the right.
      2. Close the mapping screen.
    1. The actionflow configuration is complete.
    Tip
    edc


    Always remember to test the actionflow to make sure it works.

    Insert excerpt
    _property_tabs
    _property_tabs
    namebasic-h
    nopaneltrue

    Insert excerpt
    _parent
    _parent
    nopaneltrue

    Basic Settings

    FieldDescription
    NameEnter the name for the action node.
    Insert excerpt
    _actionflow_properties
    _actionflow_properties
    nameshow-name
    nopaneltrue

    Insert excerpt
    _actionflow_properties
    _actionflow_properties
    nameshow-text
    nopaneltrue

    Pass Through

    Specify whether or not to allow data that has not been processed to pass through to the next action node. 

    Insert excerpt
    _check_box_untick
    _check_box_untick
    nopaneltrue
     to prevent data that is not processed by this node from passing to the next action node. 

    Insert excerpt
    _check_box_tick
    _check_box_tick
    nopaneltrue
     to allow data that is not processed to pass through to the next action node.

    Calculate Attributes

    Calculate actions process data using expressions; see pages in the topic Expressions and PhixScripts.

    This section has a toolbar with standard buttonsThe grid contains a list of the expressions that the calculate action will perform. 

    • To add a new expression, in the section toolbar click 
      Insert excerpt
      _add
      _add
      nopaneltrue
       to open a new expression and set the properties.
    • To edit an existing expression, double-click it in the list to open its properties.
    • To remove an expression, select one and in the section toolbar click 
      Insert excerpt
      _delete
      _delete
      nopaneltrue
      .

    Calculate Attributes Properties

    Parent Details

    Basic Settings

    Field

    Description
    NameEnter the name of the calculate attribute.
    Type

    Select one of the data types:

    • String
    • Bigstring
    • Integer
    • Float
    • Decimal
    • Date
    • Datetime
    • Graphic
    • TrueFalse
    Note

    Make sure you select the same data type as that of the attribute to which you are mapping; see Understanding Data Types.


    Attribute Name

    Insert excerpt
    _check_box_tick
    _check_box_tick
    nopaneltrue
     to indicate the calculate attribute matches the name of an attribute in the data.

    Expression

    Enter an expression. To work in a larger pop-up window, click Image Modified.

    See also:

    OrderWhere the calculate action runs multiple expressions, enter a number to indicate the order in which this expression will be run. Remember that an expression that generates a value should run before an expression that uses the value.


    Insert excerpt
    _description
    _description
    nopaneltrue

    Insert excerpt
    _property_tabs
    _property_tabs
    nameaccess-h
    nopaneltrue

    Insert excerpt
    _access
    _access
    nopaneltrue

    Insert excerpt
    _audit
    _audit
    nopaneltrue

    Live Search
    spaceKey@self
    additionalnone
    placeholderSearch all help pages
    typepage

    Panel
    borderColor#00374F
    titleColorwhite
    titleBGColor#00374F
    borderStylesolid
    titleSections on this page

    Table of Contents
    maxLevel3
    indent12px
    stylenone


    Learn More

    For links to all pages in this topic, see Understanding Actionflows


    Insert excerpt
    _terms_changing
    _terms_changing
    nopaneltrue