Please ensure Javascript is enabled for purposes of website accessibility
Powered by Zoomin Software. For more details please contactZoomin

AVEVA™ Plant SCADA

Conditions

  • Last UpdatedJul 13, 2023
  • 3 minute read

Conditions can be used for defining dependencies in a composition. For example, if a parameter needs to be displayed based on the value selected for another parameter or a composition needs to be applied based on a set of conditions. Conditions are of the following types:

  • Global Conditions

  • Parameter Conditions

  • Composite Conditions

The order in which conditions are defined is important because only a condition defined later can use conditions defined before it. This is to avoid cyclical reference. For example, you have defined Global condition "MEO" first followed by condition "SmallMeter". The "SmallMeter" condition can use "MEO" as a Parameter condition, but the "MEO" condition cannot use the "SmallMeter" condition (shown in Example 1 below).

Before going through details about the types of conditions, it is important to understand operators that can be used to define conditions. The section below provides details of the different types of operators.

Operators

Conditions can be defined with the help of operators. Operators are of two types:

  • Logical – This include "AND" and "OR". These operators can be used when defining Composite conditions.

  • Comparison – The following comparison operators are available to perform comparisons for string, integer and Boolean values:

Operator

Used for Comparing Values of Data Types...

IsEqualTo

Boolean, String and Integer

IsNotEqualTo

Boolean

IsGreaterThan

Integer

IsGreaterThanOrEqualTo

IsLessThan

IsLessThanOrEqualTo

StartsWith

String

EndsWith

Contains

Global Conditions

Global conditions are conditions that need to be used frequently within an XML template. They are defined once and can be used anywhere within an XML template to incorporate parameter dependencies or selection of a composition. Global conditions can also be used:

  • to pre-define the components of the Composite Genie that can be enabled or disabled

  • in determining parameter dependency, and can be used in one or more compositions within the XML template.

They may include nested Parameter as well as Composite conditions (shown in Example 2 below).

Global conditions are defined using the GlobalCondition element, which comprises the following attributes:

Attribute

Description

Name

User friendly name for the condition, which needs to be unique.

Example

In this example, the Global condition "Show_LabelPadding" is met when the one of the predefined Global conditions in the Composite condition is met.

Example

This example shows a nested condition that can be used to evaluate a Global condition.

Parameter Conditions

Parameter conditions can be used in a composition within the Prerequisite element to determine the composition that will be selected based on user input and to toggle visibility of a parameter. Parameter conditions are also used to define Global conditions. The attributes of a Parameter condition include:

Attribute

Description

Name

User friendly name for the condition, which needs to be unique.

Value

Expected value of the parameter against which the condition will be evaluated.

Example

Composite Conditions

Composite conditions are conditions that are joined together with the AND or OR operator and function as a group. Composite conditions can be made up of Global or Parameter conditions.

Attribute

Description

Operator

This can be set to "AND" or "OR" and determines how the conditions needs to be evaluated.

Example

In the sample code, two parameter conditions are joined together using the AND operator.

See Also

Visual Template

Parameters

Content Items

Compositions

Prerequisites

Container

Alarm Indicators

In This Topic
TitleResults for “How to create a CRG?”Also Available in