Variables

enaio® 11.10 »

Variables are created in the model explorer on the Variables tab.

Variable types for logging and a corresponding global 'wfProtocol' variable are predefined. You can use a variable to manage logging. Resources for the application languages are available in the system for displaying the names of the variable values: German, English, French.

You must set up scripts for logging. The variables for logging are included in the standard ad-hoc workflow.

The osDate, osTime, osActivity, osUser, and osAction variables can be used in any model and are also specified there in the preset application language.

Variable Types

Enter the type for variables.

The following variable types are available:

  • String
  • String consisting of the default character set. The maximum length is defined through the size of a BLOB field in your database.

    The maximum length of string variables that can be processed in processes is substantially less than the length of a BLOB field and needs to be checked in the project.

  • Integer
  • Integer from -231 to 231

  • DateTime
  • Date/time in the format set in the operating system

  • Time
  • Time in the format preset in the operating system

  • Date
  • Date in the format preset in the operating system

  • Float
  • Floating-point number

  • Record
  • Records of variables of different types

  • List (String)
  • List of variables of type 'String'

  • List (Integer)
  • List of variables of type 'Integer'

  • List (Float)
  • List of variables of type 'Float'

  • List (Record)
  • List of a record consisting of variables of different types

  • wfOrgObjectListType
  • Use the variable type 'wfOrgObjectListType' only for variables in fields that have the workflow-recipient add-on assigned to them.

You can create your own variable types and use them as variables.

In most cases, the variables you create can be global except in cases where they might change variables of parallel activities.

You have to configure variable transfer for non-global variables.

In addition to type-safe variable types, string-based variable types are also listed; they will lead to display errors if you have set up local date and time formats in enaio® and a language other than German in the operating system. These string-based variable types should not be used. In running installations that always work with German date and time formats, you do not need to edit existing workflow models with string-based variable types. If you want to internationalize a running system, you must replace string-based variables with type-safe variables.

Creating Variables

Create variables using the context menu.

  • Choose New variable from the context menu or click the Add icon.
  • Enter a unique name.
  • Whether in ANSI or Unicode systems, variable names must start with an ANSI letter and cannot contain spaces but only ANSI letters, alphanumeric characters, and underscores.

  • Optionally, enter a description.
  • Choose a type from the list.
  • Select the option 'global' if you want to treat this variable as a global variable. For non-global variables, you have to configure a variable transfer in the activities.
  • Select 'Multilingual catalog' if you want to link this variable to a multilingual catalog. The variable must be global and a 'String' variable.

    Then select the multilingual catalog that has been set up for a form from the list.

    The variable must be assigned to the form field of the multilingual catalog as a parameter of the application so that the multilingual values will be displayed.

  • Confirm by pressing OK.

The variable is created and displayed on the tab.

Simple variables are shown in blue, records and lists in red, and variables of a custom variable type in white. Global variables are labeled as such:

String-based variables have a gray type description instead of a black one:

For 'Record' or 'List (Record)' variables you have to add the variables of the record:

  • Select the entry 'Record'.
  • Choose Edit structure from the context menu.
  • Click on the Add icon.
  • Enter a unique name.
  • Choose a type from the list.
  • Confirm by pressing OK.
  • The variable will be displayed in the record variables list.

  • Add further variables.
  • Confirm by pressing OK.

Record variables are assigned to the record and displayed on the Variables tab.

Record variables can be deleted, but not edited, in the Edit record dialog.

Variable Types

Variable types are created in the same way as variables. Choose Add > Variable type from the context menu and enter a name and a type.

Variables you created on your own are displayed in the variable type list on the Variables tab.

Each variable you created is listed in the variable type list once it has been created and is available for use.

Defaults

'String', 'Integer', 'DayTime', and 'Float' variables can be assigned preset values.

Choose Default from the context menu of a variable and enter a value.

When presetting type-safe variables, bear in mind that values must be entered according to the internally used German format: 'Date' and 'Time' variables must use the German date and time format (e.g., 03.06.2008 and 14:04:18), 'DateTime' variables must be an integer, and 'Float' variables must follow the point notation (e.g., 1234.56). The model validation will include this information.
If you do not specify the default values, 'Integer' variables are automatically preset to '0'.

Click the Save button in the toolbar of the model editor to save changes made to the model data.

Input/Output Parameters

Values are assigned to variables during a workflow process. If you want to start a workflow process with the transfer of variable values, or if you want to forward variable values to other processes after a workflow process is completed, you have to define variables as input/output parameters.

Processes can be launched from enaio® capture and from Microsoft Outlook, for example, with the transfer of values.

On the Input/output parameters tab, define variables as input parameters, as output parameters, or as input and output parameters.

  • Choose New parameter from the context menu or the toolbar.
  • Choose a variable from the variable list.
  • Enter a type:
  • Input parameters

    The variable can contain a value when the process starts.

    Output parameters

    The value of the variable can be forwarded at the end of the process.

    Input/output parameters

    The variable may contain a value at the start of the process which can be forwarded at the end of the process.

  • Confirm by pressing OK.

The variable and type are displayed on the tab.

Click the Save button in the toolbar of the model editor to save changes made to the model data.