Professional Documents
Culture Documents
W O N D E R W A R E T R A I N I N G
Training Manual
Revision A
February 2019
Part Number 11-HM-10038
Copyright © 2019 AVEVA Group PLC and its subsidiaries. All rights reserved.
Table of Contents 1
Wonderware Training
Module 1 – Introduction
Section 1 – Course Introduction 1-3
Section – InTouch Software Overview 1-7
Section 2 – System Requirements and Licensing 1-9
Section 3 – InTouch Application Types 1-13
Lab 1 – Creating the Modern InTouch Application 1-17
1-2 Module 1 – Introduction
Module Objectives
List the objectives of the course and establish the agenda
Discuss the key components of InTouch
List the system requirements and licensing
Discuss the InTouch Application types
Wonderware Training
Section 1 – Course Introduction 1-3
Course Description
The tag-based InTouch HMI 2017 Update 3 course is a 5-day, instructor-led class that explains
how to create and configure a Modern InTouch application. The course provides a fundamental
understanding of the Wonderware visualization module and the steps necessary to develop a
Human Machine Interface (HMI) system for a plant floor. You are guided through setup, layout,
best practice concepts, features, and functions of the InTouch HMI software platform. Hands-on
labs reinforce concepts and features.
Objectives
Upon completion of this course, you will be able to:
Create a Modern InTouch Application
Build an HMI with Situational Awareness symbols
Construct a Key Performance Indicator display
Configure a Communication Driver
Establish communications with I/O-aware programs
Create, export, and import tags
Test and monitor tags
Build a custom symbol
Visualize and interact with data
Configure InTouch alarms
Present and manage live and historical alarms
Configure security
Historize and trend data
Display real-time data
Back up and restore an InTouch application
Distribute an application to a production environment
View ArchestrA graphics in a browser using Web Client
Audience
Individuals who need to configure or modify InTouch HMI applications
Prerequisites
Knowledge of the following tools, features, and technologies is required:
Industrial automation software concepts for InTouch HMI
Microsoft Excel for exporting, modifying, and importing tags with a .csv file
Module 1 – Introduction
Section 1 – Course Introduction
This section will explain the objectives and agenda for this course. It will also outline
Wonderware products and how InTouch meets the human-machine interface requirements for
visualization.
Section 2 – InTouch Software Overview
This section will introduce the InTouch, explains the benefits of using InTouch, discusses its
key capabilities, and provides an overview of its features.
Section 3 – System Requirements and Licensing
This section will describe the operating systems and other software requirements the host
computer must meet prior to installing InTouch 2017 (version 17.3).
Section 4 – InTouch Application Types
This section will provide an overview of the different types of InTouch applications.
Wonderware Training
Section 1 – Course Introduction 1-5
This section will explain the capabilities and usage of the Situational Awareness Library.
Section 2 – Element Styles
This section will discuss element styles and the Application Style Library. It will also explain
how to import and export the Application Style Library.
Section 3 – Window Construction Using Symbol Editor
This section will explain the capabilities of the ArchestrA Symbol Editor for designing entire
window graphic assemblies and custom graphics.
Section 4 – Custom Properties and Animations in Symbols
This section will provide a brief overview of the graphic tools in the ArchestrA Symbol Editor
that pertain to adding custom properties and animations.
This section will provide an overview of the various InTouch QuickScript types, and describe
the features and functions that are unique to each QuickScript type. This section will also
explain the QuickScript Editor.
Module 9 – Security
Section 1 – OS Security Implementation
This section will discuss how to prepare your environment for using OS security. This section
will also provide an overview of scripting for OS security.
Section 2 – Locking Down Your Application
This section will provide an overview of the Animation Links dialog box and explain Action
Script methods you can use to secure your application. This section will also describe the
function used to enable and disable the Alt, Escape, and Windows keys.
Wonderware Training
Section 1 – Course Introduction 1-7
This section will introduce the InTouch, explains the benefits of using InTouch, discusses its key
capabilities, and provides an overview of its features.
Key Benefits
The key benefits of InTouch are:
Developers and operators can create applications quickly and efficiently
Device integration and connectivity
Visual representation and interaction that brings the right information to the right people at
the right time
Simplified migration from older to newer versions of the software, preserving investment in
engineering
Key Capabilities
The key capabilities of InTouch are:
Resolution-independent graphics and intelligent symbols to speed up design
Sophisticated scripting to extend and customize applications for specific needs
Real-time distributed alarming with historical views for analysis
Built-in, real-time, and historical trending
Microsoft .NET controls integration
Extensible library of predesigned, customizable graphics and symbols
Wonderware Training
Section 2 – System Requirements and Licensing 1-9
Hardware Recommendations
The following table provides guidelines for hardware configurations suitable for Wonderware
System Platform 2017 software based on the size of the installation. These guidelines are subject
to the limitations of your Windows operating system.
Hardware Requirements
Small Installation (1 - Medium Installation Large Installation (>50K
25K I/O per Node) (25K - 50K I/O per Node) I/O per Node)
CPU Cores (Minimum)1 Greater than or equal to 2 Greater than or equal to 2 Greater than or equal to 8
RAM (GB)1 Greater than or equal to 4 Greater than or equal to 8 Greater than or equal to 16
Storage (GB)2 Greater than or equal to Greater than or equal to Greater than or equal to
30 500 1000
Network (Mbps) Greater than or equal to Greater than or equal to Greater than or equal to
100 1000 1000
1 In redundant environments, increase CPU and RAM to maintain a maximum of 40% typical resource utilization.
2 Minimum amount of storage needed to provide sufficient capacity for 1 week at max frequency.Software Requirements for InTouch 2017
Note: Windows operating systems and SQL Server versions may impose hardware requirements
that exceed the minimum requirements for InTouch HMI 2017.
Note: The Intel Itanium 2 processor is not supported. We recommend 1280 x 1024 as the
minimum display resolution for engineering tools such as the Integrated Development
Environment (IDE).
Note: A Windows Server operating system is required for large installations with more than
50,000 I/O per node.
Note: SQL Server Express is not supported for installations with more than 25,000 I/O per node
(small installations only).
.NET Notes
Versions of .NET (other than 4.x versions) can coexist, but all .NET code, including QuickScript
.NET scripts, run under .NET 4.5.1.
.NET 3.5 is installed only because the supported SQL Server versions require it. No other
dependencies must exist.
Note: Windows Server 2012 R2 is the recommended operating system for a Galaxy Repository.
Microsoft Windows 8.1 (32-bit or 64-bit) is the recommended operating system to run InTouch
runtime client components. Microsoft Windows Server 2012 R2 is the recommended operating
system to run InTouch server components.
Encrypted Communications
The end to end communication between software applications (server and client) can be
encrypted and secured to prevent eavesdropping and malicious tampering (aka: Man-in-the-
Middle) attacks.
To enable encrypted network communication, one of the nodes in the network must be configured
to host and run the System Management Server. The role of the System Management Server is to
generate, manage, and distribute secure digital certificates used for establishing and maintaining
secure communications.
All other nodes need to be configured to connect to the SMS so they all become part of the same
community.
The System Management Server does not need to be available at runtime for secure
communications to be established. In fact, once joined to the System Management Server, a node
will not need access to the System Management Server until it is time to renew the certificates.
Wonderware Training
Section 2 – System Requirements and Licensing 1-11
Licensing
Wonderware enforces the use of its products with a software license. InTouch uses the License
Server to make licenses available. The License Manager manages one or more License Servers.
Use the License Manager interface to make licenses available to InTouch. First, import the
entitlement .xml file received upon purchase of the license. Then, select which licenses on the
entitlement to activate on the License Server. Once activated, it becomes available to
WindowMaker or WindowViewer upon start up. The license is released when InTouch is shut
down.
InTouch will run in Demo Mode if it cannot consume a valid license at start up time.
To install licensing, see the Licensing Guide.
Wonderware Training
Section 3 – InTouch Application Types 1-13
Overview
You use the InTouch Application Manager to manage most global tasks such as creating InTouch
applications, deleting InTouch applications, and modifying the name, description, and path of your
InTouch applications. Application Manager shows a list of your current InTouch applications. Once
you have created an InTouch application, it appears as a record in the Application Manager. From
there you can select an application from the list to open in WindowMaker or WindowViewer.
The InTouch Application Manager allows you to create three types of InTouch applications:
Legacy, Modern, and Published.
Application Templates
An Application Template provides a mature starting point for creating a Managed or Modern
InTouch application. This feature reduces design time by creating reusable standards from pre-
built starter applications.
Target Resolution
A target resolution allows the user to create an application for a production environment with a
screen resolution that is different than the Engineering node. Target resolution is specified during
application creation and can be modified after an application has been created. When a window is
being created, target resolution provides a guideline to stay within the target resolution size.
Historically, InTouch automatically converted the resolution of the original application to match the
resolution of the computer where the application is running. This conversion process could have
had a severe impact on the position of graphics or the placement of windows in an application.
Therefore, the Target Resolution feature prevents automatic conversion by setting the size of the
application up front, regardless of the resolution on the computer that it is being run. If Target
Resolution is set to default resolution, this is equivalent to enabling the automatic conversion
feature.
Wonderware Training
Section 3 – InTouch Application Types 1-15
Wonderware Training
Lab 1 – Creating the Modern InTouch Application 1-17
Introduction
In this lab, you will create a Modern InTouch application using the InTouch Application Manager.
From Application Manager, you will lock the window size of your application for development in
subsequent labs. Then, you will open your Modern InTouch application in WindowMaker.
Objectives
Upon completion of this lab, you will be able to:
Create a Modern InTouch application
Set the target resolution to the resolution on a target computer
Open a Modern InTouch application in WindowMaker for editing
2. Click Next.
The starting directory search screen appears.
Wonderware Training
Lab 1 – Creating the Modern InTouch Application 1-19
7. Click Next.
8. In the application directory field, enter InTouch Training Application.
Wonderware Training
Lab 1 – Creating the Modern InTouch Application 1-21
9. On the Select target resolution drop-down list, ensure Screen Resolution is selected.
Wonderware Training
Lab 1 – Creating the Modern InTouch Application 1-23
14. In the Properties dialog box, check the Lock Window Size check box.
Note: Double-clicking the InTouch Training Application from the list will also open
WindowMaker.
Wonderware Training
Lab 1 – Creating the Modern InTouch Application 1-25
Note: Lock Window Size can also be enabled on the WindowMaker Properties dialog
box. However, if you enabled Lock Window Size here, instead of the InTouch Application
Manager, you would be required to restart WindowMaker.
Wonderware Training
Module 2 – Window Layout and Basic
Navigation
Section 1 – WindowMaker Overview 2-3
Section 2 – WindowViewer Overview 2-7
Section 3 – Configure and Test Navigation Using WindowMaker 2-9
Lab 2 – Setting Up Windows and Navigation 2-11
2-2 Module 2 – Window Layout and Basic Navigation
Module Objectives
Discuss how to lay out Windows
Embed an ArchestrA graphic and configure wizard options
Add a Show Window animation to an embedded graphic
Wonderware Training
Section 1 – WindowMaker Overview 2-3
Overview
WindowMaker is the InTouch application editor used to create and define windows, graphics,
animations, the layout of your windows, and the look and feel of your HMI application.
WindowMaker includes a graphical tool set that is used to design InTouch interfaces.
WindowMaker can also be used to configure and maintain features such as scripts, graphics,
ActiveX controls, .NET clients, alarms, historical logging, and security to create and manage the
visual interface.
WindowMaker helps you build an InTouch application that is comprised of windows that can
contain graphics, text, animations, navigation elements, window scripts, and action scripts. When
you create a window, the window properties of the window are defined, such as background color,
title, and screen position.
InTouch Windows
InTouch is comprised of windows that can contain graphics, text objects, animations, and action
scripts. When a window is first created, properties of the window itself such as title, background
color, and dimensions are defined.
When a new window is created, behaviors and aesthetic properties are defined in the Window
Properties dialog box. You can specify whether or not a window will automatically close other
windows that it intersects with, or position the window on top or behind open windows. Border
style, position and size, and background color can also be defined.
When a new window is created, the default settings are retained from the previously created
window, or of the currently active window. Window names can contain up to 32 characters and can
include any character on the keyboard except quotation marks.
Window Types
Window Type options include the following:
Replace – Automatically closes any windows it intersects when it appears on the screen,
including popup and replace type windows.
Overlay – Appears on top of the currently displayed windows and can be larger than the
windows it is overlaying. Clicking on any visible portion of a window behind an overlay
window makes that window active.
Popup – Is similar to an overlay window, yet always stays on top of all other open
windows even if another window is clicked.
Frame – This window type is used to host a single ArchestrA graphic. Frame windows
enable panning and zooming at runtime.
Template Windows
Template Windows are reusable application windows that act as a model, or starting point, for
creating new windows; which aid in establishing application design standards. Template windows
are different from other windows as the Template property is enabled, they are listed separately
from other windows in WindowMaker, they can be selected from the Template Window browser,
and they can be used as a template to create new windows.
Embed ArchestrA Graphic can be used to open the ArchestrA Symbol Library
and view the library of available ArchestrA graphic symbols
Wonderware Training
Section 1 – WindowMaker Overview 2-5
Wonderware Training
Section 2 – WindowViewer Overview 2-7
Overview
InTouch WindowViewer is the runtime visualization application, where users can view and control
processes in a visual display format with animations and user interfaces. It executes scripts,
interfaces with the alarm manager and the historical data retrieval and storage system, drives
animations, connects to IO data, displays graphics and text, and provides interactive tools for
supervisory control and data acquisition.
Menus in WindowViewer allow you to perform basic functions such as opening and closing
windows, starting and stopping logic, logging into and out of security, launching the tag testing tool
Tag Viewer, starting and stopping historical logging, and exiting WindowViewer.
WindowViewer monitors user input by responding to peripheral devices such as a mouse when a
user clicks a graphic. For example, an operator clicks an input field to change a set point, or an
operator might click a button to navigate to a new window.
WindowViewer also supports automation through scripting as a scripting execution engine. Tasks
which require 24-hour-a-day monitoring can be triggered to execute by WindowViewer
automatically without an operator present.
Wonderware Training
Section 3 – Configure and Test Navigation Using WindowMaker 2-9
Configure Navigation
A typical window layout built using WindowMaker will include a menu window. A menu window
typically contains some interactive method the user selects to change the content being displayed
in WindowViewer. To provide this interaction, windows are arranged in such a way that the menu
window is always visible as the user navigates to different content. The navigation commonly
takes the form of buttons, where each button represents a single window that can be displayed.
Therefore, each button will be labeled with the name of the window it displays and the animations
applied to it will display that window.
For small applications, rows of buttons is easily manageable. However, it is not scalable for
medium to large applications. This course will explain more than one method of navigation.
Wonderware Training
Lab 2 – Setting Up Windows and Navigation 2-11
Introduction
In this lab, you will create windows in WindowMaker, and configure properties and dimensions of
the windows to arrange them into a layout that will be used throughout this course. Then, you will
embed a symbol from the ArchestrA Graphic Toolbox into a window, edit the label on the symbol,
and add an animation that will allow you to interact with the symbol to open a window. You will
duplicate the symbol and edit the duplicate to produce a row of buttons that open different
windows. Finally, you will test your window layout and navigation in runtime using WindowViewer.
Objectives
Upon completion of this lab, you will be able to:
Create a basic application window layout
Create a menu window
Create a Frame window
Create a Template window
Create a window from a Template window
Embed an ArchestrA symbol on a window
Add a Show Window animation to a button on a menu
Test what you have configured in Runtime using WindowViewer
Wonderware Training
Lab 2 – Setting Up Windows and Navigation 2-13
X Location: 0
Y Location: 0
Window Width: 1800
Window Height: 100
6. Click OK.
The new Menu window is listed under the Windows folder in the Windows & Scripts pane,
and is open on the canvas.
Wonderware Training
Lab 2 – Setting Up Windows and Navigation 2-15
X Location: 0
Y Location: 100
Window Width: 350
Window Height: 580
The KPI window is listed under the Windows folder in the Windows & Scripts pane, and is
open on the canvas.
Next, you will create Template windows and create windows from these templates.
11. On the File menu, select New Window.
12. In the Name field, enter Content_NonFrame.
Wonderware Training
Lab 2 – Setting Up Windows and Navigation 2-17
X Location: 350
Y Location: 100
Window Width: 1450
Window Height: 580
Wonderware Training
Lab 2 – Setting Up Windows and Navigation 2-19
Because the settings from the previous template window have become the default settings, the
Window Type, Title Bar, Template, and Dimensions are already configured.
21. Click OK.
The Content_Frame window is listed under the Template Windows folder in the Windows &
Scripts pane, and is open below the Menu window on the canvas.
Next, you will create a new window from a Template window. To do this, you must first save and
close all Template windows.
22. Click the Save All Windows button.
23. In the Windows & Scripts pane, right-click the Content_Frame template window and select
Close.
Wonderware Training
Lab 2 – Setting Up Windows and Navigation 2-21
24. In the Windows & Scripts pane, right-click the Content_NonFrame window and select
Close.
Wonderware Training
Lab 2 – Setting Up Windows and Navigation 2-23
Notice that Template is not checked because this is a window created from a Template window.
28. In the Name field, enter Mixer.
Next, you will create the remaining template and windows that will be used in this course.
30. On the File menu, select New Window, and configure the Windows Properties dialog box as
follows:
Name: Information_Frame
Frame: checked
Window Type: Replace
Title Bar: checked
Template unchecked
X Location: 0
Y Location: 680
Window Width: 1800
Window Height: 300
The Window Properties dialog box will look like the following image.
Wonderware Training
Lab 2 – Setting Up Windows and Navigation 2-25
Next, you will use the drag-and-drop method to make the Information_Frame window a Template
window.
32. In the Windows & Scripts pane, drag the Information_Frame window onto the Template
Windows folder.
The Information_Frame template window can now be used as a template to create other
windows.
Wonderware Training
Lab 2 – Setting Up Windows and Navigation 2-27
Next, you will create two windows from the Information_Frame template window.
33. Save and close the Information_Frame template window.
34. Use the Information_Frame template window to create a new window named Current
Alarms.
Note: In the Template Window Browser, you will need to scroll down to locate the
Information_Frame template window.
35. Use the Information_Frame template window to create a new window named
Historical Alarms and Events.
36. Save and close the Historical Alarms and Events window.
Wonderware Training
Lab 2 – Setting Up Windows and Navigation 2-29
39. In the Menu window, right-click the embedded instance, and select Substitute | Substitute
Strings.
Wonderware Training
Lab 2 – Setting Up Windows and Navigation 2-31
42. On the Arrange toolbar at the bottom of WindowMaker, click the Rotate Clockwise button.
The Mixer symbol is rotated.
43. If necessary, use the arrow keys to ensure the entire Mixer symbol is completely visible within
the Menu window.
44. Right-click the Mixer symbol, and select Animation Links.
Wonderware Training
Lab 2 – Setting Up Windows and Navigation 2-33
The symbol is now a button that opens the Mixer window when clicked at runtime.
49. Ensure the Mixer button is selected, then right-click and select Duplicate.
50. Drag the duplicate button to the right of the Mixer button.
Wonderware Training
Lab 2 – Setting Up Windows and Navigation 2-35
51. Right-click the duplicate button, and select Substitute | Substitute Strings.
52. In the New String field, enter Alarms.
Test in Runtime
Finally, you will test what you have configured in runtime by opening WindowViewer.
60. In the upper-right corner of WindowMaker, click Runtime.
After a moment, WindowViewer opens showing the Menu window, the KPI window, the Mixer
window, and the Current Alarms window.
Wonderware Training
Lab 2 – Setting Up Windows and Navigation 2-37
Wonderware Training
Lab 2 – Setting Up Windows and Navigation 2-39
66. Right-click the WindowViewer icon on the task bar and select Close window.
WindowViewer closes.
Wonderware Training
Module 3 – InTouch Tagname Dictionary
Section 1 – The Tagname Dictionary 3-3
Lab 3 – Defining Memory Tags 3-11
Section 2 – I/O Configuration 3-19
Lab 4 – Configuring the Communication Driver 3-27
Lab 5 – Creating I/O Access and I/O Tags 3-37
Section 3 – Tag Viewer 3-49
Lab 6 – Watching Tags with Tag Viewer 3-55
Section 4 – DBDump and DBLoad 3-69
Lab 7 – Exporting and Importing Tags 3-73
Section 5 – Other Tag Management Utilities 3-85
3-2 Module 3 – InTouch Tagname Dictionary
Module Objectives
Demonstrate how to use the InTouch Tagname Dictionary
Define an InTouch Access name
Configure an IO Server
Create I/O Tags
Wonderware Training
Section 1 – The Tagname Dictionary 3-3
Overview
At the most basic level, a Tag is a named value. Tags are used to store and manipulate values and
properties, such as minimum and maximum ranges or alarm information. Defining tagnames and
properties is done in the InTouch Tagname Dictionary. For communication bandwidth, storage size
and efficiency, and proper handling each tag is defined with a specific data type which designates
that tag for a specific use. In runtime, WindowViewer loads and maintains a copy of the dictionary,
which is updated with all current values and properties for these tagnames.
During runtime, an InTouch application accesses the Tagname Dictionary and provides specific
tag information via animation links, and InTouch subsystems such as Alarms, History, Security,
and scripting.
You can set up an InTouch application to identify a subset of data stored on another node by using
a three-part naming convention. This convention includes the node, application, and topic names.
To obtain data from a remote node, you must configure an Access name for your InTouch
application that specifies these three items.
You must associate InTouch I/O tags with an Access name. Additionally, each I/O tag definition
includes the Item name which, for example, is equivalent to the memory address in a PLC. Tags,
including I/O configuration, and Access names are described in more detail in the following
sections.
Memory Tags
Memory tags are InTouch application tags that do not acquire data from a remote source. For
example, memory tags can store the results from a mathematical calculation performed in an
InTouch QuickScript. WindowViewer can act as an I/O server and provide results to an external
client application requesting this Memory tag.
Memory tags are also used in animations such as a counter used to control a Location or Fill
animation. Memory tags can be used as a logic state flag in a QuickScript or used to track the
toggle state of an action pushbutton. Memory tags also serve as simulation data during the design
phase of an InTouch application where linking to I/O data is not yet possible or presents a risk until
the design is tested and proven.
There are four Memory types:
Memory Discrete: Internal discrete tag with a value of either 0 (False or Off) or 1 (True or
On)
Memory Integer (Analog): A 32-bit signed integer value in whole numbers
Memory Real (Analog): Floating (decimal) point value calculated in 64-bit precision stored
in 32-bit precision
Memory Message: Text string tag that can be up to 131 characters
I/O Tags
All tags that read or write their values to or from an external source are named I/O tags. This
includes all inputs and outputs from programmable controllers, process computers, and data from
network nodes.
I/O tags are accessed either through the Microsoft Dynamic Data Exchange (DDE) or Wonderware
SuiteLink communication protocols. SuiteLink is a proprietary Wonderware protocol recommended
for network communication and diagnostics with other Wonderware I/O applications.
When the value of a read/write I/O tag changes, it is immediately written to the remote application.
The tag can also be updated from the remote application when the item to which the tag is linked
changes in the remote application.
By default, all I/O tags are set to Read/Write. However, you can restrict them to read only by
selecting the Read Only option in the Tagname Dictionary dialog box.
There are four I/O Types:
I/O Discrete: Discrete input/output tag with a value of either 0 (False, Off) or 1 (True, On)
I/O Integer (Analog): A 32-bit signed integer value
I/O Real (Analog): Floating (decimal) point tag
I/O Message: Text string input/output tag that can be up to 131 characters long
Wonderware Training
Section 1 – The Tagname Dictionary 3-5
$System Tags
There are a number of pre-built $System tags in the Tagname Dictionary. These $System tags
provide data for security, date information, time information, and miscellaneous functions, such as
determining the vertical and horizontal position of the current selection. $System tags cannot be
deleted or renamed.
$System tags such as $OperatorEntered and $PasswordEntered allow data to be written to
them, allowing these tags to be used to create a login feature for InTouch Security.
$ConfigureUsers, opens the configure users security dialog box when a value of 1 is written to
the tag, but only if the user has the proper access level. Several of the $System tags are also
predefined to log events to the Alarms and Events subsystem when it is enabled. For example,
each time a new alarm occurs, the $NewAlarm tag is set to 1, and this incident is recorded in the
event history.
Group Var
Use the Group Var type for a tag with an assigned Alarm Group to create dynamic alarm displays,
disk logs, and print logs. Group Var tags create alarm windows or alarm logs that display all alarms
associated with a specific group variable. You can also control the alarms that are displayed or
logged by assigning a different Alarm Group to the Group Var tag.
Hist Trend
InTouch requires a Hist Trend tag type when you create a historical trend. All of the fields
associated with historical trends can be applied to Hist Trend tags.
Tag ID Tags
Use Tag ID tags with historical trend objects. Use Tag ID tags to retrieve information about tags
being plotted in a historical trend. In most cases, Tag ID tags display the name of the tag assigned
to a specific pen or to change the tag assigned to the pen.
Creating Tags
Tags and their tagnames are created using the Tagname Dictionary.
There are several ways to open the Tagname Dictionary:
Menu bar: Special | Tagname Dictionary
Tools pane shortcut: Tagname Dictionary
Keyboard shortcut: Ctrl+T
The first time you access the Tagname Dictionary, the definition for the internal system tagname
$AccessLevel appears. This is the first tag in the Tagname Dictionary.
After saving a tag definition in the Tagname Dictionary, the definition for the tag edited last is
displayed.
Many tags require a greater level of detail to be properly handled. A Details area is displayed for
each type of tag to define the details and alarm types for the tag type. This section is seen only if
the Details or Details & Alarms radio buttons are selected at the top of the Tagname Dictionary.
The fields which are shown in the details area vary based on the Type selection.
Wonderware Training
Section 1 – The Tagname Dictionary 3-7
Configuring Tags
The following configuration options are available in the Tagname Dictionary.
Group
The Group button assigns the tag to a specific Alarm Group.
Comment
Additional text that can be used to describe the tag. The comment cannot exceed 50 characters.
Log Data
Enables historical logging to the InTouch Historical Logging subsystem. Log Deadband adds a
tolerance to the data logged by the historical logging subsystem. This is used to reduce the
consumption of storage space.
Log Events
Enables tracking of tag state changes to the Alarm and Event subsystem.
Retentive Value
Retains the current value of the tag when WindowViewer is closed.
Wonderware Training
Section 1 – The Tagname Dictionary 3-9
Retentive Parameters
Retains the current alarm limit when WindowViewer is closed.
Alarm Comment
This field contains default alarm comment text string which can be used when an alarm is
acknowledged.
Wonderware Training
Lab 3 – Defining Memory Tags 3-11
Introduction
In this lab, you will create Memory Real, Memory Integer, Memory Discrete, and Memory Message
tags. Some of these tags will be used in subsequent labs.
Objectives
Upon completion of this lab, you will be able to:
Define memory tags
Wonderware Training
Lab 3 – Defining Memory Tags 3-13
4. Click Type.
6. Click OK.
The Memory Discrete tag type displays to the right of the Type button.
8. Click Save.
Wonderware Training
Lab 3 – Defining Memory Tags 3-15
9. Click New.
Notice that the Tagname field automatically increments to Tag_Discrete2.
Tagname: Tag_Real
Type: Memory Real
Note: Remember that you must click the New button prior to creating a new tag, or your
existing tag will be overwritten.
Wonderware Training
Lab 3 – Defining Memory Tags 3-17
19. Repeat the previous steps to create another tag and configure it as follows:
Tagname: Tag_Message
Type: Memory Message
20. Click Close to save the tag definition, and exit the Tagname Dictionary.
Note: Do not confuse the typical Windows Close button [X] at the top right side of the
Tagname Dictionary, which cancels the current definition and exits the window.
Wonderware Training
Section 2 – I/O Configuration 3-19
Communication Drivers
The OI Server Manager is a part of the SMC suite of utilities. It enables the configuration,
diagnosis, activation, or deactivation of a local OI Server or a remote OI Server located on a
different node from the OI Server Manager.
You can open multiple instances of the OI Server Manager at the same time; however, you can
only use the first instance to create device hierarchies and configure an OI Server. In all other
instances of the OI Server Manager hierarchy and configuration settings are set to read-only.
Server Groups
A server group comprises one or more server instances that use the same OI Server protocol,
such as a Modbus-MBTCP. When you install a specific OI Server on a computer, a server group
and default server instance are automatically created for that OI Server in the OI Server Manager.
Since there is a limit of one server group per OI Server per computer node, that server group
effectively is the OI Server.
Where the server group appears in the OI Server Manager depends on what type of OI Server it is
for. For the purpose of this course, the MBTCP is optimized and is contained in the Operations
Integration Supervisory Servers folder.
Wonderware Training
Section 2 – I/O Configuration 3-21
Server Instances
Each server instance has its own configuration and diagnostics, can be activated and deactivated
separate from all other server instances, and appears as a separate application to external clients.
When you install an OI Server on a computer, a server group and a default server instance are
automatically created for that OI Server in the OI Server Manager. The name of the default server
instance is based on the short name of the OI Server installed. For example, for the Wonderware
Simulation OI Server, the default server instance is named OI.SIM.1. All server instance names
follow this basic format.
The middle part of a server instance name becomes the application name that external clients will
use to access OI Server data. For example, if a server instance is named OI.SIM_0001.1, the
corresponding application name will be SIM_0001. This middle part of the server instance name is
used in the InTouch runtime client, WindowViewer, to connect to this data source.
Log Viewer
The SMC also includes a health monitoring system for all Wonderware applications, named the
Log Viewer. The Log Viewer runs as a system service. The Log Viewer records information
regarding the activity occurring on the computer. For example, it records start-up data, error
conditions, and OI Server information.
The Log Viewer is a troubleshooting tool that is installed automatically with the installation of every
Wonderware application. The Log Viewer should be checked occasionally to monitor the health
and configuration of any Wonderware system.
Note: The Log Viewer highlights error messages in red. These indicate malfunctioning processes
and should be resolved quickly. Warning messages are highlighted in yellow. These indicate major
events in the system. Text not highlighted indicates informational messages only.
Wonderware Training
Section 2 – I/O Configuration 3-23
Using Bookmarks
Bookmarks are unique labels applied to individual messages for quick access. You cannot enter
duplicate bookmark names for more than one message, and a messages can have only one
bookmark. The Message window can display a Bookmark column, which is initially hidden by
default, but can be shown by using a configuration setting.
Set bookmarks in two ways: adding a regular bookmark that you can name and setting a fast
bookmark that is named for you.
Note: Bookmarks are not saved when you quit the Log Viewer application. To mark your message
log more permanently, use the Mark command on the View menu.
PLCSim
The PLCSim used in this course is the Mod_RSsim.exe. It is a publicly available application which
requires script-based logic to represent a simulation, commonly written in Visual Basic. The
student media supplied with this course contains this executable along with its supporting
Mixer.VBS script. To work with the Modbus TCP protocol used by this simulator application, an OI
Server from Wonderware is required. The OI Server used for this course is MBTCP. It is purchased
and licensed separately and therefore not included with the student media. A standard InTouch
license includes the ability to use two I/O servers.
Option Purpose
Access Name The Access name must be unique for each I/O source (typically the same as the topic
name). InTouch uses Access names to reference real-time I/O data. Each Access
name is associated with an I/O source that must be on the same network as the
InTouch Application Node.
Node Name The Node Name is the computer name or IP address of the computer on the network
which is hosting the I/O source. A blank Node Name implies local node access.
Application Name The Application Name is the process or executable running on the remote computer,
which InTouch will connect to. Note: Do not enter the .exe extension portion of the
program name.
Topic Name The Topic Name is the device group, scan group, or channel used by one or more
items (PLC memory addresses) that will be polled at a specific frequency or rate. The
OI Server will contain the same spelling of the topic name in its device group list
configuration.
Which Protocol to Select DDE (local node only) for support of older Wonderware I/O servers, or
use connections to Microsoft Office products; or SuiteLink (Wonderware proprietary
network protocol).
When to advise Advise all items: Select if the server program is to poll for all data whether or not it is
server in visible windows, alarmed, logged, trended or used in a script. Selecting this option
impacts performance and is not recommended.
Advise only active items: Select if the server program is to poll only points in visible
windows and points that are alarmed, logged, trended, or used in any script. An
InTouch Pushbutton action script is not polled unless it opens in a visible window.
Wonderware Training
Section 2 – I/O Configuration 3-25
Tagnames. However, by controlling the Device Item Map in the OI Server, you could restrict the
alias names used in the item map by using only characters supported in InTouch tagnames. This
would allow you to still use the Use Tagname as Item Name feature. This is the approach used in
this course.
The Item name does not have to match the tagname. The Item name field in the InTouch Tagname
Dictionary supports a wider range of symbols and characters than a tagname name field. This
allows you to work with hundreds of field device manufacturers’ unique naming conventions. For
example, the Item name field supports the common characters: space( ) and period(.). Whereas,
both of these characters are not supported in InTouch tagnames.
In the definition of an analog I/O tag there are two parts that control the data from the remote
source. These are referred to as Raw and EU. The Raw value allows you to scale device values in
cases where the PLC does not already perform scaling.
The EU, which represents the Engineering Units as seen by a human, can be used to scale the
Raw value coming from the field device. To scale, select the value range from the field device such
as 4 to 20ma or 0 to 4095 for example. And then in the EU fields select the equivalent engineering
units that the human operator will use.
For example, a temperature transducer measures 0 to 100 degrees Fahrenheit. The PLC provides
this temperature as an analog to digital converted value ranging 0 to 4095. In the Min Raw field
you would enter 0, and in the Max Raw field you would enter 4095. However, in the MinEU field
you would enter 0 and in the MaxEU field, 100. The value is then linearly scaled by interpolating
between the Raw and the EU mathematically. Therefore, if the temperature memory address in the
PLC contains 3276 then InTouch will scale this to 80 degrees Fahrenheit, and 80 degrees
Fahrenheit could be displayed on an InTouch window in runtime.
If, on the other hand, this I/O tagname was a set point for the temperature, the above scaling
works in reverse. The user would enter 80 degrees Fahrenheit as the set point and InTouch would
write 3276 to the PLC memory address.
If the PLC is performing all scaling you would not scale the tag in InTouch. In such cases, the Raw
value will reflect the range of the scaled value. To do this the Raw fields and the EU fields both
contain the same numbers. For example, Min Raw and MinEU would both contain 0, and Max
Raw and MaxEU would both contain 100. This would establish a ratio of 1 to 1 (1:1).
Wonderware Training
Lab 4 – Configuring the Communication Driver 3-27
Introduction
In this lab, you will configure an OI Server named MBTCP. This is the OI Server you will use to
connect to a Modbus simulator to provide PLC data throughout this course. Then, you will
configure the OI Server using the System Platform Management Console (SMC). Finally, you will
import a previously configured device item definition list contained in a .csv file. This list is used to
configure aliases for PLC items.
Objectives
Upon completion of this lab, you will be able to:
Configure an OI Server using the SMC
Note: Your instructor will provide the name of the Production node.
6. Click OK.
Wonderware Training
Lab 4 – Configuring the Communication Driver 3-29
Wonderware Training
Lab 4 – Configuring the Communication Driver 3-31
13. In the Network Address field, enter the name of the Production node where the PLC
simulation is running.
Note: Your instructor will provide the name of the Production node.
Wonderware Training
Lab 4 – Configuring the Communication Driver 3-33
Note: Be sure to change the name of the default value from Topic_0 to Topic1 before
pressing Enter or moving to another tab. This name will be used as the Access name in
InTouch in a later lab.
16. Click the Device Items tab, right-click inside the table, and then select Import.
17. In the Open dialog box, navigate to C:\Training, and select PLCItemList.
18. Click Open.
After the .csv file is imported, the table will be populated.
19. In the top-right corner, click the Save button to save the configuration.
Wonderware Training
Lab 4 – Configuring the Communication Driver 3-35
After it becomes activated, the white x becomes a white check mark inside of a green border.
A license file icon appears, indicating that the server is running and licensed.
Wonderware Training
Lab 5 – Creating I/O Access and I/O Tags 3-37
Introduction
In this lab, you will create an Access name to connect to the Communication Driver. Then, you will
create I/O tags to access device item data from the PLC simulator.
Objectives
Upon completion of this lab, you will be able to:
Create an Access name for the Communication Driver
Create I/O tags
Wonderware Training
Lab 5 – Creating I/O Access and I/O Tags 3-39
4. In the Node Name field, enter the name of the Production node where the PLC simulator is
running.
8. Click Close.
Wonderware Training
Lab 5 – Creating I/O Access and I/O Tags 3-41
12. Click Type, and in the Tag Types dialog box, check the I/O Discrete check box.
Notice the tagname has been copied into the Item field, but it is grayed out so it cannot be
edited. The Item name can be edited by changing the name of the tag. Otherwise, you must
uncheck Use Tagname as Item Name to edit the Item field.
Wonderware Training
Lab 5 – Creating I/O Access and I/O Tags 3-43
Note: Remember to click New before defining a new tag and to click Save after the definition
is complete.
Wonderware Training
Lab 5 – Creating I/O Access and I/O Tags 3-45
Initial Value: 0
Min EU: 0
Max EU: 300
Deadband: 0
Min Raw: 0
Max Raw: 4095
Eng Units: DegF
Log Deadband: 0
Conversion: Linear
Note: In the Tagname field, you will need to change Mixer101 to Mixer100.
Tagname: Mixer100_Level_PV
Max EU: 1000
Eng Units: Gallons
Wonderware Training
Lab 5 – Creating I/O Access and I/O Tags 3-47
Tagname: Mixer100_Inlet1_Position
Type: I/O Integer
Min EU: 0
Max EU: 100
Min Raw: 0
Max Raw: 10
Eng Units: %
Access Name: PLCSim
37. Retain the remaining default settings, and click Close to save the current definition and exit
the Tagname Dictionary.
Wonderware Training
Section 3 – Tag Viewer 3-49
Overview
Tag Viewer is an application that allows you to watch and monitor tags, and modify tag values at
runtime. It provides you with a list of all available tags in the application arranged hierarchically,
based on their alarm groups. It displays tags available in the local InTouch application and does
not support remote references.
Tag Viewer is useful during engineering troubleshooting and diagnostic testing. It also reduces
application development and diagnostic time, and enhances application stability and reliability by
providing real-time direct runtime access to the Tagname Dictionary.
To use Tag Viewer, you must first enable it in WindowMaker and then start it from WindowViewer.
You can then start the application at runtime. It can be started through a script or the special
function menu.
Note: You can open only one instance of Tag Viewer at a time.
You can monitor the value, time, and quality of a tag in the watch window to determine if the data
you receive is good, and identify data related issues. Issues include loss of communication or mis-
configured tags.
.Value
Contains the value of the specified tagname. This is also the default dotfield for every InTouch
tagname within the system. If no other dotfield is specified, this dotfield is assumed.
.Time
Time dotfields represent updated time stamps and can be integer, string, or real data types based
on the time values being shown. For example, the .TimeDate indicator is an integer tagname
dotfield used to display the whole number of days since 01/01/1970. TimeDate would then contain
a number which represents the time that has passed since the I/O server sent the value.
Wonderware Training
Section 3 – Tag Viewer 3-51
. Quality
The Wonderware data quality standard is based on the Open Platform Communications (OPC)
proposed quality, which is based on Fieldbus data quality specifications.
Quality flags represent the quality state for the data value of an item. This design makes it fairly
easy for both servers and client applications to determine how much functionality they want to
implement. Wonderware InTouch typically uses a dozen of these codes.
The Quality field allows the user to access the quality of an I/O tagname as provided by an I/O
Server. If the I/O connection becomes invalid, the quality dotfields are automatically reset to the
initial value of zero. The .ReferenceComplete dotfield is also set to zero to indicate incomplete.
When the client application is unable to communicate with the server .QualityStatus is 0.
The following list shows some of the common codes that are returned by the .Quality dotfield:
Good (.Quality of 192)
The communications link has been verified
The PLC understood the poll request and returned a valid response packet
If a write occurred, there were no errors during the write process
There were no conversion problems with the data contained in the response packet
Example: The value 0x0000A is returned due to a poll of a register containing 10 (decimal).
Clamped High (.Quality of 86)
The communications link has been verified
The PLC understood the poll request and returned a valid response packet
The register was read or written without error
It was necessary to clamp its intended value to a limit because the value was larger than
the maximum allowed
In the case of a string, the string is truncated
Example: An unsigned 16-bit integer is clamped to 65535.
Clamped Low (.Quality of 85)
The communications link has been verified
The PLC understood the poll request and returned a valid response packet
The register was read or written without error
It was necessary to clamp its intended value to a limit because the value was smaller than
the minimum allowed
Example: An unsigned 16-bit integer is clamped to 0.
Wonderware Training
Section 3 – Tag Viewer 3-53
Wonderware Training
Lab 6 – Watching Tags with Tag Viewer 3-55
Introduction
In this lab, you will use Tag Viewer to monitor I/O data and check the health of I/O communication
for your tags.
Objectives
Upon completion of this lab, you will be able to:
Create watch windows containing tags
Determine the value, time, and quality of I/O tags
Save a watch window in Tag Viewer
Simulator Process
In this course you will use a PLCSim process that simulates a Mixer tank, which adds two
ingredients, blends them together, and then drains the mixer.
The process begins with Inlet1 valve opening and Pump1 running. The Level begins to increase.
Once the Level reaches 60%, the Inlet1 valve closes and Pump1 stops running.
Simultaneously, the Inlet2 valve opens and Pump2 starts running. The Level increases to
approximately 100% (intentionally, the logic in the simulator does not fill the tank to exactly 100%
every single time.)
At 100%, the Inlet2 valve closes and Pump2 stops running. The agitator starts mixing for a time
(typically, 15 seconds). The agitator then stops. At this point the Outlet valve opens and the tank is
drained to 0%.
During the entire process, the Temperature increases and decreases randomly.
The entire process takes approximately 1 minute and 30 seconds, and then repeats itself
indefinitely.
Note: WindowViewer configuration changes, such as enabling Tag Viewer, require WindowViewer
to restart. WindowViewer is currently shut down. Therefore, the configuration changes will take
affect the next time WindowViewer starts.
Wonderware Training
Lab 6 – Watching Tags with Tag Viewer 3-57
3. Click the Window Configuration tab, and check the Tag Viewer check box.
Note: This will add a new Tag Viewer menu option under the Special menu at runtime.
4. Click OK.
5. In WindowMaker, click Runtime.
Wonderware Training
Lab 6 – Watching Tags with Tag Viewer 3-59
In the left pane, a list of all of the tags in the application is displayed.
8. In the tag list, scroll down, and while holding down the Ctrl key, select the following tags:
Mixer100_Inlet1_Position
Mixer100_Inlet2_Position
Mixer100_Outlet_Position
9. Drag and drop the 3 tags down onto the watch list.
All three tags are identified as I/O type because they show a current timestamp.
Wonderware Training
Lab 6 – Watching Tags with Tag Viewer 3-61
10. In the watch list window, right-click and select Rename Tab.
13. In the watch list, click in the empty space to ensure that you have no tags selected.
14. Right-click in the empty space and select Add Separator.
Wonderware Training
Lab 6 – Watching Tags with Tag Viewer 3-63
18. In the watch list, right-click the empty space, and select Add Separator.
19. Add the following tags to the watch list:
Mixer100_Level_PV
Mixer100_Temperature_PV
Wonderware Training
Lab 6 – Watching Tags with Tag Viewer 3-65
25. Add the following tags to the Memory Tags watch window:
Tag_Discrete1
Tag_Discrete2
Tag_Integer
Tag_Message
Tag_Real
26. Verify that all memory tags do not have a timestamp and have a quality of 192.
The reason memory tags do not have a timestamp and the quality is defaulted to 192 is
because they are defined as memory tags and not I/O tags.
Wonderware Training
Lab 6 – Watching Tags with Tag Viewer 3-67
Wonderware Training
Section 4 – DBDump and DBLoad 3-69
Overview
When you back up the Tagname Dictionary using the DBDump utility, a copy of the Tagname
Dictionary is exported to a file that can be opened by external applications. These files can be
manipulated externally and loaded back into the Tagname Dictionary using the DBLoad utility to
replace existing entries or add new tags.
The Tagname Dictionary is a convenient tool for creating tags. It is a simple interface that makes
this job quite easy. However, when creating thousands of tags for a large application, this task can
be time consuming. You can streamline tag development of large amounts of similar tags using
DBDump and DBLoad to make bulk additions or changes.
These two utilities allow you to copy, modify, or create tags and then load them into one
application. The DBDump and DBLoad utilities are started from the InTouch Application Manager
for Legacy (stand alone) and Modern InTouch.
DBDump
Use the DBDump utility to export the Tagname Dictionary from a Modern InTouch application to a
file. The file contains a list of all the tags contained in the Tagname Dictionary. This list can be
organized into section headers based on the type of tag as defined in the Tagname Dictionary. The
file also contains a list of all of the Access names.
DBLoad
Use the DBLoad utility to load, update, or replace a Tagname Dictionary in a Modern InTouch
application from a file. Prior to loading the file, the contents of the file can be modified with mode
switches instructing DBLoad how to handle conflicts. A conflict happens is when a tag in the file
matches a tag that already exists in the Tagname Dictionary. The mode switch determines how the
conflict is handled.
For example, mode=ask, the default, will prompt the user for every conflict encountered. If you are
loading the same file that was just dumped using DBDump, this could mean responding to tens of
thousands of prompts. For this reason, mode=replace is more often used to create new tags or
modify existing tags. However, this option can be dangerous without a backup of your application
prior to using DBLoad. Therefore, DBLoad will prompt you to backup your application before every
use.
You can create a database input file template by creating a new InTouch application and then
running the DBDump program before any new tags have been created. The resulting exported file
represents a template of the Tagname Dictionary format used by the DBDump and DBLoad
utilities.
DBDump and DBLoad is the most common method used to modify tags because it accommodates
version control and tracking of changes made to tags.
Using DBLoad, it is possible to:
Create tags
Modify existing tag properties, such as Access names and Item names
Change logging properties
Make mass changes to the Tagname Dictionary
Keyword Description
:Mode Specifies how duplicate tag records are handled when importing the contents using
DBLoad
:IOAccess Access names defined for the InTouch application
:AlarmGroup Alarm groups defined for the InTouch application
:MemoryDisc Memory discrete tags
:IODisc I/O discrete tags
:MemoryInt Memory integer tags
:IOInt I/O integer tags
:MemoryReal Memory real tags
:IOReal I/O real tags
:MemoryMsg Memory message tags
:IOMsg I/O message tags
:GroupVar Group Var tags
:HistoryTrend Hist Trend tags
:TagID Tag ID tags
:IndirectDisc Indirect discrete tags
:IndirectAnalog Indirect analog tags
:IndirectMsg Indirect message tags
Wonderware Training
Section 4 – DBDump and DBLoad 3-71
Each tag type header keyword includes a set of attributes that specify the properties of Access
names, alarm groups, and the fields used by the Tagname Dictionary. For example, the :IOAccess
keyword includes attributes to specify the node, application, topic, and communication protocol,
which are properties of every InTouch Access name.
All data records must begin with the valid keyword for the tagname :type, followed by the valid
keyword for each data record (separated by commas). For example,
:IOMsg,Group,Comment,Logged,EventLogged,Event Logging Priority, …
Note: If a tag is renamed in the file, DBLoad creates a new tag rather than delete the original tag
instance. DBLoad cannot delete a tag from the Tagname Dictionary.
Wonderware Training
Lab 7 – Exporting and Importing Tags 3-73
Introduction
In this lab, you will use the DBDump utility to export all of the mixer tags in your application to a
.csv file. You will then modify the .csv file to create another set of mixer tags. These new tags will
link automatically with the PLC simulator configured in an earlier lab. Next, you will import the new
tags from the .csv file and verify that the new tags were created. Then you will use Tag Viewer to
test the communication and quality of the new tags. Finally, you will use the DBLoad utility to add
the remaining mixer tags that will be used throughout the rest of the labs.
Objectives
Upon completion of this lab, you will be able to:
Use the DBDump utility to export tags to a .csv file
Use Microsoft Excel to modify the definition of tags in a .csv file
Use the DBLoad utility to load the modified .csv file to create new tags
4. Ensure InTouch Training Application is selected, and click the DBDump button.
InTouch Application Manager closes and the CSV File to Dump To dialog box appears.
5. In the Directories list, double-click [..].
Wonderware Training
Lab 7 – Exporting and Importing Tags 3-75
7. Click OK.
A Dump successful message appears.
8. Click OK.
Note: Before the next step, ensure that .csv (Comma delimited) is in the Save as type
field.
15. Press Ctrl+H to open the Find and Replace dialog box.
16. In the Find what field, enter Mixer100, and then in the Replace with field, enter Mixer200.
Wonderware Training
Lab 7 – Exporting and Importing Tags 3-77
26. Ensure InTouch Training Application is selected and click the DBLoad button.
InTouch Application Manager closes and the Database Load dialog box appears.
Important: Using the DBLoad utility to replace or modify existing tags can present a risk if the
.csv file is not properly formatted or if errors are introduced by the user. Therefore, it is a best
practice to have a backup of your application, which may be used to restore the application in
the event the Tagname Dictionary becomes corrupted. In this course, you will cover the
detailed steps to properly back up and restore your application in a later lab.
Wonderware Training
Lab 7 – Exporting and Importing Tags 3-79
Test in Runtime
Next, you will use Tag Viewer to verify the existence and health of all of the mixer tags.
32. Open the InTouch Application Manager.
33. Double-click the InTouch Training Application to open WindowMaker.
After a moment, WindowMaker opens and the Windows to Open dialog box appears with no
windows checked.
34. Click OK.
35. Click Runtime.
36. On the WindowViewer Special menu, select Tag Viewer.
37. In the watch list, right-click in the empty space, and select Load Watch List.
38. In the Select a File dialog box, navigate to the C:\Training folder, and open the My Watch
List file.
Wonderware Training
Lab 7 – Exporting and Importing Tags 3-81
42. In the watch list right-click in the empty space and select Save Watch List.
47. Ensure InTouch Training Application is selected, and click the DBLoad button.
48. In the Database Load dialog box, click Yes.
49. In the CSV File to Load From dialog box, Files list, select AllMixerTags.CSV.
Wonderware Training
Lab 7 – Exporting and Importing Tags 3-83
Wonderware Training
Section 5 – Other Tag Management Utilities 3-85
The Cross Reference utility is a modeless window dialog box. This allows you to leave the cross
reference open while working in WindowMaker. This is handy when searching and modifying tag
names and tag values identified in the cross reference list, particularly large applications with tens
of thousands of tags. The initial time to open the Cross Reference utility can take several minutes.
Wonderware Training
Section 5 – Other Tag Management Utilities 3-87
Deleting Tags
When a tag is referenced by any script or animation, it cannot be deleted. Use the Cross
Reference tool to determine everywhere the tag is applied.
The Delete button is not available in the Tagname Dictionary if either WindowViewer is running or
the tag is being used in the application. Therefore, techniques must be applied to free tag usage
before a tag can be deleted.
In other words, to delete an unused tag from the Tagname Dictionary, you must complete the
following tasks:
Shut down WindowViewer
Determine tag use with the Cross Reference utility
Delete the tag from all windows, animation links, Failover configuration, ActiveX and .Net
Controls and scripts containing the tagname
Update Use Counts
Delete the tag from the Tagname Dictionary or the Delete Unused Tags utility for bulk tag
deletion
Note: References to a tag inside of quotes (“ “), such as within a script or animation link, excludes
this tag from the use counts check and will cause it to appear in the Delete Unused Tags utility. Be
cautious when deleting any tag that you may be unfamiliar with.
Wonderware Training
Module 4 – Situational Awareness
Visualization
Section 1 – ArchestrA Symbols and Situational Awareness Visualization 4-3
Section 2 – Element Styles 4-9
Lab 8 – Building a Dashboard 4-11
Section 3 – Window Construction Using Symbol Editor 4-43
Lab 9 – Building the Mixer Operational Display 4-51
Section 4 – Custom Properties and Animations in Symbols 4-95
Lab 10 – Building a Command Symbol 4-101
4-2 Module 4 – Situational Awareness Visualization
Module Objectives
Define the concepts of the Situational Awareness Library
Describe Element Styles
Explain the levels of Situational Awareness Displays
Create detailed displays (similar to P&ID and workflow or procedural displays)
Explain the features of Situational Awareness symbols
Visualize data with displays built using the Situational Awareness Library
Wonderware Training
Section 1 – ArchestrA Symbols and Situational Awareness Visualization 4-3
Overview
The pre-built graphics available out of the box with InTouch are divided into two graphic types. The
first type is Legacy graphics, which are file-based, rasterized, and native to WindowMaker. The
second type is ArchestrA graphics, which are database stored, vectorized, and handled outside of
WindowMaker. Our focus for this course will be on ArchestrA graphics.
ArchestrA graphics are divided into two libraries: the ArchestrA Symbol Library, and the Situational
Awareness Library. Symbols from these two libraries are accessed from the ArchestrA Graphic
Toolbox.
When you place a symbol in the graphic toolbox onto a window, this is referred to as embedding
an instance. It is like making a copy of the symbol for use in the window. When you edit the graphic
in the graphic toolbox the changes are propagated, or pushed, to all of the instances of that
symbol throughout the application. This design approach allows you to maintain standards and
propagate modifications everywhere without having to make changes to each instance of the
symbol manually.
After a symbol has been embedded into a window it can be linked to tags so that the graphics
displayed in the window will show current process values in runtime. For example, a pump graphic
has tags linked to command override, operation hours, set point, open limit switch and closed limit
switch, operating temperature, power consumption, and other process values which are
represented on the screen graphically for the pump.
Graphic Assemblies
Symbols from the library can be embedded into another symbol. Using this technique, you could
create an entire process window by assembling valves, pumps, temperature, and level symbols
together inside a single symbol which represents a process. This concept is named a graphic
assembly. A graphic assembly is still referred to as a single symbol, which can then be embedded
on a window and named up using navigation to display the state of the process.
Wonderware Training
Section 1 – ArchestrA Symbols and Situational Awareness Visualization 4-5
response to critical situations. These traditional HMIs made it difficult to identify normal conditions,
and overloaded the operator’s attention.
Symbols in the Situational Awareness Library were designed to simplify the visual input the
operation must process in order to take action.Through a limited use of color and a strategic use of
animation, the operator's focus can be directed to the point in the process that requires immediate
attention.
The Situational Awareness philosophy was created to encompass the following design guidelines:
Rational use of color
Data in context
Reduce mental workload
Support for common assessment tasks
Standardization
Integrated alarming
Information density
“Big Picture” overviews
User-centered design
Task analysis design
Using the Symbol Wizard, a single Situation Awareness Library symbol can support multiple
configurations by showing or hiding functional elements as options that are part of the default
symbol set.
Wonderware Training
Section 1 – ArchestrA Symbols and Situational Awareness Visualization 4-7
As you can see from the table, the InTouch Tag Type called Discrete is typically mapped to the
Boolean Custom Property type in ArchestrA Symbols. Where a 0 or 1 from the Discrete tag in
InTouch corresponds to False or True or 0 or 1 in ArchestrA Symbols. However, ArchestrA
Symbols will not generate an error or complain if any numerical data type is used for Boolean; it is
simply translated as 0 or non-zero. Where zero is False and non-zero is True.
The InTouch Tag Type called Integer is typically mapped to the Integer Custom Property in
ArchestrA Symbols. Integer represents whole numbers without fractions, such as -56 or 2568.
The InTouch Tag Type called Real is typically mapped to either a Float or Double Custom
Property in ArchestrA Symbols. Real represents high resolution values which include a
fractional part, such as -0.336 or 3235.9.
For the InTouch Tag Type called Message, it is typically mapped to the String Custom Property
in ArchestrA Symbols. Message represents string or text data, but may contain numerical
characters and symbols. Message tags in InTouch are limited to 131 characters in length. This
is NOT a restriction of ArchestrA String Custom Properties, so this must be taken into
consideration. In addition to the String Custom Property type, InTouch Message tags can also be
linked to the Custom Property types for Time and Elapsed Time, which contain a date and time
character mask for representing time data, in String format.
Wonderware Training
Section 2 – Element Styles 4-9
Element Styles
An element style defines a set of visual properties that determine the appearance of text, lines,
graphic outlines, and interior fill shown in ArchestrA symbols or graphics. An element style applied
to a symbol sets preconfigured visual property values that take precedence over native visual
properties of a symbol.
Element styles provide the means for developers to establish consistent visual standards in their
ArchestrA applications. An element style can define the same visual properties of text, lines, fill,
and outlines for all symbols or graphics that belong to an application. Likewise, element styles can
show the current status of an object represented by a symbol. For example, an element style
animation can be applied to a symbol when an object transitions to an alarm state.
Wonderware Training
Lab 8 – Building a Dashboard 4-11
Introduction
In this lab, you will add two Situational Awareness Library dashboard symbols to a window. Then,
you will configure the wizard options, link tags, and position these symbols to present summary
data at runtime. You will also use the Application Style Library to override element styles.
Additionally, you will convert a window into an ArchestrA graphic.
Objectives
Upon completion of this lab, you will be able to:
Configure wizard options for the look and behavior for Situational Awareness symbols
Link InTouch tags to custom properties of Situational Awareness symbols
Visualize I/O data coming from multiple sources
Override a default element style in the Application Style Library
Import an Application Style Library
Convert a window to an ArchestrA symbol
Wonderware Training
Lab 8 – Building a Dashboard 4-13
Note: Do not resize or reposition the symbol at this time because the wizard options and
choices in the following steps will change the dimensions and appearance of the symbol. You
will resize and reposition the symbol in a later step.
Wonderware Training
Lab 8 – Building a Dashboard 4-15
9. In the Bar01A details pane, Default Value field, remove the --- placeholder.
10. On the right side of the Default Value field, click the ellipsis button .
Wonderware Training
Lab 8 – Building a Dashboard 4-17
12. Click OK to select the tag and close the Select Tag dialog box.
The tagname is displayed in the Default Value field.
13. Repeat the previous steps to configure the custom property as follows:
j
Bar01B: Mixer100_Totalizer2_PV
Bar02A: Mixer200_Totalizer1_PV
Bar02B: Mixer200_Totalizer2_PV
Bar03A: Mixer300_Totalizer1_PV
Bar03B: Mixer300_Totalizer2_PV
Bar04A: Mixer400_Totalizer1_PV
Bar04B: Mixer400_Totalizer2_PV
Note: Ensure the placeholder (---) is removed before each tag is selected.
Wonderware Training
Lab 8 – Building a Dashboard 4-19
15. Right-click the SA_ColumnChart_Pairs symbol, and select Substitute | Substitute Strings.
Wonderware Training
Lab 8 – Building a Dashboard 4-21
18. Resize and position the symbol to the right side of the window, leaving space on the left for the
data values to grow and still be fully displayed.
The lower-right corner of WindowMaker shows the position and size of the graphic. These
fields can be edited directly by double-clicking the numbers in the status bar and pressing
Enter after making a change. The values shown here may be used to match the image as
shown.
19. In the ArchestrA Graphic Toolbox, drag SA_BulletGraph to the bottom of the KPI window.
Do not reposition or resize the graphic at this time.
Wonderware Training
Lab 8 – Building a Dashboard 4-23
20. Double-click the embedded instance of SA_BulletGraph to open the Edit Symbol Properties
dialog box.
21. In the Wizard Options pane, select PartialRange.
22. On the PartialRange details pane, Value drop-down list, select True.
23. Click the Custom Properties tab, and ensure Actual is selected.
24. Maximize the Edit Symbol Properties dialog box.
25. In the Actual details pane, replace --- with Mixer100_Totalizer3_PV +
Mixer200_Totalizer3_PV + Mixer300_Totalizer3_PV + Mixer400_Totalizer3_PV.
Note: Entering the addition symbol (+) as part of the expression in the Default Value field
does not require spaces around the operator. However, spaces do help with readability and
are recommended.
Note: The AlarmSeverity Custom Property default value is set to 2. This selects the High
Severity Level 2 alarm border which is yellow in color. This will be seen at runtime.
Wonderware Training
Lab 8 – Building a Dashboard 4-25
28. Right-click the SA_BulletGraph symbol and select Substitute | Substitute Strings.
29. Configure the Substitute Strings dialog box as follows:
Current String New String
# #
#.# #.#
Chart Heading Produced Product
Main Label All Mixers
Short Desc Gallons
Short Description Batch Totals
31. Resize and position the symbol to the left side of the window, leaving space on the right.
The lower-right corner of WindowMaker shows the position and size of the graphic.
Wonderware Training
Lab 8 – Building a Dashboard 4-27
Test in Runtime
Next, you will test the configured symbols in runtime.
32. Click Runtime.
In the WindowViewer KPI window, the two graphics display real-time data.
Note: The yellow alarm border indicates that the production output is not meeting the target
of 6500.
Wonderware Training
Lab 8 – Building a Dashboard 4-29
38. With the Actual_Value_Moving_Element selected, click the Fill (Fs) tab.
39. In the Fill Color Override area, to the right of the Fill Color Override check box, click the
color box.
Wonderware Training
Lab 8 – Building a Dashboard 4-31
Test in Runtime
Next, you will test the configured symbols in runtime.
43. In WindowMaker, click Runtime.
44. In the KPI window, in the Produced Product bullet graph symbol, verify that the current value
indicator is represented by a light blue ellipse.
Wonderware Training
Lab 8 – Building a Dashboard 4-33
Test in Runtime
Next you will test the new element style in runtime.
52. In WindowMaker, click Runtime.
53. Verify that all of the Situational Awareness graphics use a denim-colored application style.
Notice that the override for the Actual_Value_Moving_Element that was light blue is now
black.
Wonderware Training
Lab 8 – Building a Dashboard 4-35
58. In the Windows & Scripts pane, right-click the KPI window, and select Convert to ArchestrA
Symbol.
Wonderware Training
Lab 8 – Building a Dashboard 4-37
The Converting Windows to Symbols dialog box appears and begins converting the
symbol.
The conversion report will inform you of any graphic elements that could not be converted and
the reason for this. This is particularly useful when converting legacy graphics containing
ActiveX controls, which cannot be converted to ArchestrA symbols.
62. Close the Window Conversion Report Dialog window.
63. Click Close to close the Converting Windows to Symbols dialog box.
Wonderware Training
Lab 8 – Building a Dashboard 4-39
The KPI window rapidly opens then closes. This process creates a new KPI window, backs up
the original KPI window, and names it KPI_bak.
This conversion also creates a new toolset in the ArchestrA Graphics Toolbox called
intouch training application, which contains the new KPI symbol.
64. In the ArchestrA Graphic Toolbox, expand the intouch training application toolset, and
observe that the KPI symbol has been added to the library.
The ColumnChart_Pairs and the BulletGraph have been combined into a single symbol.
Wonderware Training
Lab 8 – Building a Dashboard 4-41
You no longer need the backup copy of the KPI window. Next, you will delete the KPI_bak window.
68. In the Windows & Scripts pane, right click KPI_bak, and select Delete.
Wonderware Training
Section 3 – Window Construction Using Symbol Editor 4-43
Tools Pane
The Tools pane contains elements you can use to draw on the canvas.
Wonderware Training
Section 3 – Window Construction Using Symbol Editor 4-45
Elements Pane
The Elements pane contains a list of all the elements on the canvas.
The Elements pane is particularly useful for selecting one or more elements that are visually
hidden by other elements on the canvas. You can use the Elements pane to:
See a list of all elements, groups of elements, embedded symbols, and client controls on
the canvas
Select elements or groups of elements to work with them
Rename an element or a group of elements
The z-order of elements specifies which element appears on top of other elements when the
elements overlap on the canvas. When you place new elements on the canvas, they are placed at
the top and can cover all other elements.
The order of the elements can be changed as follows:
Bring one or more elements to the very front
Send one or more elements to the very back
Bring one or more elements one level forward
Send one or more elements one level backward
Properties Pane
You can use the Properties pane to view and configure properties for the selected element or
group of elements. These properties include wizard options, size, location, color, and fill style, as
well as runtime behavior.
Animation Summary
You can use the Animations pane to add or remove animations to elements on the canvas.
Canvas
The canvas is your drawing area. The canvas is used to draw, size, position, and edit elements.
Wonderware Training
Section 3 – Window Construction Using Symbol Editor 4-47
Rotating Elements
You can rotate elements to any orientation (0-359 degrees):
Graphically with the rotation handle
Numerically by typing the orientation angle in the Properties editor
Using the 90-degree rotation tools in a clockwise or counter-clockwise direction
The element is rotated around its point of origin. By default, the point of origin is in the center of the
element.
Wonderware Training
Section 3 – Window Construction Using Symbol Editor 4-49
When selecting tags and tag dotfields within the Symbol Editor they cannot be validated at design
time. Therefore, their color appears maroon, indicating that their source is unknown. This is normal
behavior as these tags will be bound at runtime. Some tags cannot be found in the Tag Selector.
The master alarm group tag $System and any SuperTags will not be visible from the InTouch Tag
Browser tab, but these can be typed into the Default Value field manually.
Wonderware Training
Lab 9 – Building the Mixer Operational Display 4-51
Introduction
In this lab, you will design a Mixer symbol using Situational Awareness Library graphics. The Mixer
symbol will be reused for different configurations in future labs.
You will arrange the elements in your Mixer symbol as shown in the graphic below.
Objectives
Upon completion of this lab, you will be able to:
Create a symbol in the graphic toolbox in WindowMaker and open it for editing in the
Symbol Editor
Build a graphic assembly using symbols from the Situational Awareness Library
Configure the Wizard Options for valves, pumps, meters, and an agitator
Link I/O tagnames and tagname.dotfields to custom properties within embedded symbols
Add Connection Points and Connectors to a symbol
Use the Zoom control bar features at runtime
2. Right-click the top most InTouch Training Application node, and select New | Graphic
Toolset.
Wonderware Training
Lab 9 – Building the Mixer Operational Display 4-53
Next, you will open the Mixer symbol and embed Situational Awareness Library graphics.
6. Double-click the Mixer symbol.
After a moment, the ArchestrA Symbol Editor appears.
Wonderware Training
Lab 9 – Building the Mixer Operational Display 4-55
13. On the right side of the ArchestrA Symbol Editor, in the Properties pane Name field, enter
Inlet1, and press Enter.
Note: When changing field properties, press the Enter key as a final step to retain your
changes.
14. On the Wizard Options area, ValveType drop-down list, select Analog.
Note: Double-clicking on the field will also change Wizard Options. This is particularly useful
when there are two options such as True or False.
Wonderware Training
Lab 9 – Building the Mixer Operational Display 4-57
On the canvas, the Inlet1 graphic changes to reflect the ValveType wizard option. The
graphics below show Inlet1 before and after selecting the Analog ValveType.
15. On the canvas, right-click the Inlet1 symbol, and select Substitute | Substitute Strings.
Wonderware Training
Lab 9 – Building the Mixer Operational Display 4-59
20. In the EquipStateActive details pane, Default Value field, delete False.
When the Default Value field is improperly configured, such as when it is left blank, the field is
highlighted with a red outline and the icons at the top of the details pane and in the Custom
Properties list are marked with a yellow warning triangle.
Wonderware Training
Lab 9 – Building the Mixer Operational Display 4-61
21. In the Default Value field, double-click to open the Galaxy Browser.
The Galaxy Browser appears.
Note: A magenta text color normally indicates that the reference cannot be found. However,
a reference that begins with InTouch: is an exception. This link will be resolved at runtime.
Wonderware Training
Lab 9 – Building the Mixer Operational Display 4-63
25. In the Default Value field, after the InTouch:Mixer100_Inlet1_OLS tagname, enter a space,
and then type and.
26. In the Default Value field, after the InTouch:Mixer100_Inlet1_OLS and expression, enter
another space, and then type not.
27. In the Default Value field after the InTouch:Mixer100_Inlet1_OLS and not expression, enter
a space, and click the Browse Galaxy ellipsis button.
28. In the InTouch Tag Browser tab tag list, scroll down, and select Mixer100_Inlet1_CLS.
Wonderware Training
Lab 9 – Building the Mixer Operational Display 4-65
Note: Private properties will not be shown when a symbol is embedded. For example, when
using the WindowMaker Edit Custom Properties dialog box. However, the data of these
properties will be used by WindowViewer.
32. In the Custom Properties pane, select EquipStateOutOfRange, and select Private.
33. In the Custom Properties pane, select PV.
35. In the Default Value field, double-click to open the Galaxy Browser.
The Galaxy Browser appears.
36. In the InTouch Tag Browser tab tag list, scroll down, and double-click
Mixer100_Inlet1_Position.
The Default Value field will look like the following image.
Wonderware Training
Lab 9 – Building the Mixer Operational Display 4-67
Next, you will select tagname dotfields using the Galaxy Browser.
37. In the Custom Properties pane, select PVMax, and delete the Default Value.
The Custom Properties pane will look like the following image.
Next, you will duplicate Inlet1, and in the duplicate embedded symbol you will substitute strings
and substitute references.
45. On the canvas, right-click the Inlet1 valve graphic, and click Duplicate.
Wonderware Training
Lab 9 – Building the Mixer Operational Display 4-69
46. On the canvas, drag the duplicate valve below the original valve.
47. With the duplicate selected, in the Properties pane, Name field, enter Inlet2.
48. On the canvas, right-click the duplicate valve, and select Substitute | Substitute Strings.
The Substitute Strings dialog box appears.
49. Enter Inlet 2, and click OK.
50. Right-click the Inlet2 valve, and select Substitute | Substitute References.
Wonderware Training
Lab 9 – Building the Mixer Operational Display 4-71
The Replace All button replaces all references of Inlet1 with Inlet2.
Wonderware Training
Lab 9 – Building the Mixer Operational Display 4-73
Next, you will add pumps to the Mixer symbol. The pump symbol is preconfigured with the desired
wizard options. However, you will configure the symbol strings and references.
The Edit Custom Properties dialog box will look like the following image.
Wonderware Training
Lab 9 – Building the Mixer Operational Display 4-75
Next, you will add an agitator to the Mixer symbol. The Agitator symbol is preconfigured with the
desired wizard options. However, you will configure the symbol strings and references.
71. Place the Agitator symbol to the right of Pump1 and Pump2.
72. Name the symbol Agitator.
73. Change the label to Agitator.
Note: By default the PV and PVRange custom properties are used for a variable speed
motor. The data source used in this course, PLCSim, uses a simple on/off motor for the
agitator. You configured the PV and PVRange properties as fixed values so EquipState, when
set to true, will simulate the motor running at 100%.
Wonderware Training
Lab 9 – Building the Mixer Operational Display 4-77
Wonderware Training
Lab 9 – Building the Mixer Operational Display 4-79
Change From To
Substitute Strings: Gallons DegF
Substitute Strings: Level Temperature
Substitute References (Find & Replace): Level Temperature
Next, you will add a tank to the Mixer symbol. In the Tank symbol you will enable the
CustomPropertyLabel feature so that you can modify the display name of the tank by using a
custom property. This feature will be used in future labs.
Wonderware Training
Lab 9 – Building the Mixer Operational Display 4-81
99. On the canvas, place Tank over the Agitator, Level, and Temperature embedded symbols.
100.In the Elements list, right-click Tank, and select Custom Properties.
101.With the Label custom property selected, in the Default Value field, verify the Static Text
mode is enabled.
This toggle button selects if the contents of the Default Value field will be treated as text or as
a reference.
103.Click OK.
Notice the Label for Tank is not changed. Unlike Substitute Strings, Custom Property labels
will only show in WindowViewer runtime.
104.In the Elements list, right-click Tank, and select Order | Send To Back.
Tank is positioned in the z-order behind all other elements by appearing at the bottom of the
list.
Wonderware Training
Lab 9 – Building the Mixer Operational Display 4-83
Next, you will place a Connection Point on the Tank as an anchor point for the connector pipe
that you will add between the pump and the tank.
108.Line up the cursor for the Connection Point on the left side border of the tank directly across
from the built-in Connection Point on the right side of Pump1.
Wonderware Training
Lab 9 – Building the Mixer Operational Display 4-85
112.Hover over the bottom center of the Tank until the Connection Point displays, click then drag
the Connector to the Connection Point on the lower right side of the Outlet valve.
115.In the Elements list, select Connector2, and on the Properties pane, ConnectionType drop-
down list, select Straight.
116.Create a Connector between Pump1 and the adjacent Connection Point on the Tank.
117.Create a Connector between the right side of Inlet2 and the adjacent Connection Point on
Pump2.
118.In the Elements list, select Connector4, and on the Properties pane, ConnectionType drop-
down list, select Straight.
Wonderware Training
Lab 9 – Building the Mixer Operational Display 4-87
119.Create a Connector between Pump2 and the adjacent Connection Point on the Tank.
120.On the canvas, click Inlet1, hold the Shift key down, and click Inlet2 to add it to the selection.
121.With Inlet1 and Inlet2 selected, use the up or down arrow keys on the keyboard to straighten
the Connectors between the valves and the pumps.
122.In the top-left corner of the ArchestrA Symbol Editor, click the Save and Close button.
Wonderware Training
Lab 9 – Building the Mixer Operational Display 4-89
Test in Runtime
Finally, you will open WindowViewer and test the Mixer symbol in the Mixer window.
126.Click Runtime.
WindowViewer opens and the Mixer window displays the current state of the Mixer100
process.
The process begins with the Inlet1 valve opening and Pump1 running. The Level begins to
increase. Once the Level reaches 60%, the Inlet1 valve closes and Pump1 stops running.
Simultaneously, the Inlet2 valve opens and Pump2 starts running. The Level increases to
approximately 100% (intentionally, the logic in the simulator does not fill the tank to exactly
100% every single time.)
At 100%, the Inlet2 valve closes and Pump2 stops running. The agitator starts mixing for a
time (typically, 15 seconds). The agitator then stops. At this point the Outlet valve opens and
the tank is drained to 0%.
During the entire process, the Temperature increases and decreases randomly.
The entire process takes approximately 1 minute and 30 seconds, and then repeats itself
indefinitely.
Next, you will use the features of the Frame window, including the ZoomControl toobar, to zoom
and pan the Mixer graphic.
Note: If your monitor supports touch gestures, for this runtime test, you may also try pinch to
zoom and swipe to pan using your hand.
Wonderware Training
Lab 9 – Building the Mixer Operational Display 4-91
127.In the Mixer window, on the ZoomControl toolbar drop-down list, select 125.
129.In the Mixer window, click and hold down the mouse button, and move the mouse to pan the
graphic.
130.On the ZoomControl toolbar, click the Rubber Band Zoom button.
Wonderware Training
Lab 9 – Building the Mixer Operational Display 4-93
131.In the Mixer window, click and drag a rectangle over the Temperature and Level graphics.
Notice the window is zoomed to show the area that was captured using the Rubber Band
Zoom tool. More of the window may be visible than what you captured because the window
will maintain aspect ratio.
132.On the ZoomControl toolbar, click the Rubber Band Zoom button to cancel the Rubber
Band Zoom.
Finally, you will use the mouse and keyboard to zoom and pan the Mixer graphic.
133.With the Ctrl button held down on the keyboard, and the cursor hovering over the middle of
the Mixer window, scroll the mouse wheel up and down to zoom.
The Mixer graphic is zoomed in and out at the mouse cursor position.
134.Ensure the Mixer graphic is zoomed above 100 and then on the Mixer graphic, click and hold
down the middle mouse button to pan the graphic.
Observe that the Mixer graphic has been restored to its original size.
136.Click Development!.
Wonderware Training
Section 4 – Custom Properties and Animations in Symbols 4-95
Custom Properties
Custom Properties are the only mechanism for customization of a graphic symbol. The custom
properties describe how each part of the graphic is used (Description). Custom properties define
the initial value or starting state of the graphic (Default Value). Custom properties guide the data
type required to link external values (Data Type). Custom properties can be marked Private to
prevent configuration changes when a symbol is embedded in another symbol or window
(Visibility).
You can associate custom properties with functionality you want exposed and that you want to be
reusable. You can also use custom properties to connect an embedded ArchestrA Symbol to
InTouch tags.
In the Visibility box, configure how the symbol is visible. Do one of the following:
Click Public if you want the custom property to be visible (available to be edited or used)
when this symbol is embedded in another symbol or in an InTouch Window.
Click Private if you want the custom property to be hidden. This means the property
cannot be seen or edited when the symbol is embedded in another symbol or in an
InTouch Window.
For custom properties using the String Data Type, the option is presented to treat the default
value as the text as it is entered. Otherwise the default value will be looked up as a reference or
expression. For example, tags, graphic elements, other custom properties, attributes and so on.
This switch is available only for string data types. Other data types do not offer this option.
Select the T icon (Static Text) to indicate that it is a static value. This treats the content of
the Default Value field as-is, a literal string or as text. It takes each character as shown
including white space. No calculations or lookup are performed.
Select the Tag icon (Reference or Expression) to indicate that the Default Value field
contains a link to an external reference such as a tag, custom property, or graphic element
property.
Wonderware Training
Section 4 – Custom Properties and Animations in Symbols 4-97
Animations
An animation can be applied to an element or a group of elements on the canvas. The available
animations for selection are limited by the primitive parts that make up the element or group. For
example, a text animation cannot be applied to a rectangle that has no text.
You can use animations to bind the run-time behavior and appearance of elements to ArchestrA
attributes, InTouch tags, custom properties, and other element’s properties.
For example, you can bind the vertical fill of a rectangle to an ArchestrA attribute that contains the
current level of a tank.
Animations are specific to the selected element and vary between elements of different types.
Wonderware Training
Section 4 – Custom Properties and Animations in Symbols 4-99
ZoomPercent
ZoomPercent is a read/write property that allows you to both monitor and set the zoom level
associated with the symbol hosted by a Frame window. For example, ZoomPercent = 200 will
double the default size of the graphics in a Frame window. The zoom will automatically expand
around the geometric center of the symbol that is hosted.
ZoomPercent can also be used to monitor the current zoom level applied in runtime. For example,
ZoomPercent > 100 will trigger the moment any zoom occurs on the graphic. ZoomPercent can
be a value between 100 and 5000.
Wonderware Training
Lab 10 – Building a Command Symbol 4-101
Introduction
In this lab, you will create a custom symbol to be used as a command panel for starting and
stopping pumps. You will create and configure a custom property. Additionally, you will animate the
command buttons with Pushbutton and Element Style animation types.
Objectives
Upon completion of this lab, you will be able to:
Create a custom property
Configure animations
Add a Pushbutton animation
Add an Element Style animation
Wonderware Training
Lab 10 – Building a Command Symbol 4-103
5. In the Edit Custom Properties dialog box, click the Add custom property button.
Note: To rename a custom property, first select the property, then click the selected property
text. The rename field will then be shown so the name can be edited. Press enter to accept the
name change.
8. In the CMD details pane, Data Type drop-down list, verify Boolean is selected.
9. In the Default Value field, clear the default contents and enter --- .
Three dashes represent a placeholder for Custom Properties. This suppresses error
messages until this property is linked to I/O data at a later time.
10. In the Visibility area, ensure Public is selected.
11. In the Description field, enter the following:
Used to write command overrides to field devices.
Wonderware Training
Lab 10 – Building a Command Symbol 4-105
14. On the canvas, click and drag down and to the right to draw a button.
15. Enter Start for the button text.
Wonderware Training
Lab 10 – Building a Command Symbol 4-107
Wonderware Training
Lab 10 – Building a Command Symbol 4-109
Note: When an Element Style is disabled, the configured Element Style of the element is
used.
Next, you will duplicate the button and modify the animations.
33. Duplicate the button, and place the duplicate button to the right of Button_Start.
Wonderware Training
Lab 10 – Building a Command Symbol 4-111
Wonderware Training
Lab 10 – Building a Command Symbol 4-113
53. In the CMD details pane, Default Value field, delete --- .
54. In the Default Value field, double-click to open the Galaxy Browser.
55. In the InTouch Tag Browser tab tag list, scroll down and double-click
Mixer100_Pump1_CMD.
Next, you will duplicate Pump1_CMD and in the duplicate, you will substitute references.
57. Duplicate Pump1_CMD.
58. Position the duplicate below Pump2 on the canvas.
60. With Pump2_CMD selected, right-click and select Substitute | Substitute References.
61. Use Find and Replace to replace Pump1 with Pump2.
62. Click OK to close the Substitute Reference dialog box.
63. Click Save and Close.
In WindowMaker, notice the Mixer graphic has been updated to show the new CMD buttons.
Wonderware Training
Lab 10 – Building a Command Symbol 4-115
66. To ensure automatic operation of the simulator, click Start or Stop to ensure the pumps are in
the same state as their associated valves, so that the level in the tank begins moving again.
For example, if Inlet 1 is active, then Pump 1 must also be active (Start).
67. Click Development!.
Wonderware Training
Module 5 – InTouch Alarms
Section 1 – InTouch Tagname Alarm Configuration 5-3
Lab 11 – Configuring InTouch Alarms 5-11
Section 2 – Live Alarms Management 5-31
Lab 12 – Visualizing and Acknowledging Live Alarms 5-35
Section 3 – Historical Alarms Management 5-57
Lab 13 – Visualizing and Filtering Historical Alarms and Events 5-61
5-2 Module 5 – InTouch Alarms
Module Objectives
Define InTouch Alarms
Describe the Alarm subsystem
Define InTouch Tag alarm types
Describe InTouch Alarm Properties configuration
Explain how Alarms can be visualized
Wonderware Training
Section 1 – InTouch Tagname Alarm Configuration 5-3
This section will explain how to configure a discrete alarm, and an analog limit alarm. This section
will also discuss alarm dotfields, priority, groups, severity, and advanced alarm features.
Overview
InTouch has two types of notifications: Alarms and Events.
Alarms represent warnings of process conditions that could cause problems and require a
response. You can configure alarms to require an acknowledgment even if the condition causing
the alarm has passed. This ensures that an operator is aware of events that caused a temporary
alarm state but have returned to normal.
A typical alarm is triggered when a process value exceeds a user-defined limit, such as an analog
value exceeding a hi-limit threshold. This triggers an unacknowledged alarm state that can be
used to notify the operator of a problem. Once the operator acknowledges the alarm, the system
returns to an acknowledged state.
Events are considered informational and represent normal system status messages, and do not
require an operator response. A typical event is triggered when a certain system condition takes
place, such as an operator logging into InTouch. If configured to do so, InTouch can log an event to
the alarm database and print it out to a printer.
Any tag can be configured to do event monitoring while you are defining it in the Tagname
Dictionary. When you define a tag to do event monitoring, an event message is logged to the alarm
system each time the tag value changes. The event message logs how the value changed,
whether the operator, I/O, scripts, or the system initiated the change.
Alarms are enabled in the Tagname Dictionary on a tag-by-tag basis. As a supervisory system,
InTouch is frequently used to monitor discrete alarm outputs from a PLC or DCS system. Then,
InTouch is used primarily to track operator information based on who acknowledges, or who is
logged into the system when an alarm occurs. InTouch can add value with three types of analog
alarm monitoring that may not exist in an existing hardware based system:
Limit Alarms – used to track Lo, LoLo, Hi, and HiHi value limits which can also be
changed in Runtime through InTouch dotfields.
Rate of Change Alarms – used to compare a previous alarm value and its timestamp,
and the current value and timestamp, to determine the value has changed by too much
during that period.
Minor and Major Deviation Alarms – Used to monitor that the current alarm value does
not drift too far from the target value specified. Events are informational data, triggered
when a tag changes is enabled by checking the log events option for any tag type. Events
can be used, for example, to monitor the start-stop cycles on a piece of equipment to
determine the maintenance period. Events can be disabled globally for all tags through
WindowMaker configurable enabled events. Events are not displayed in a live alarm
display and are only shown in the Historical Display option.
Alarm Groups
Tag Viewer allows you to watch tags and monitor their values at runtime. You can view all tags
available in the application. The tags are arranged in a tree structure, based on their alarm groups.
It provides you with a list of all available tags in the application arranged hierarchically, based on
their alarm groups.You can group alarms to make tracking and management easier. Alarm groups
are logical representations of different areas of a factory, pieces of equipment, operator
responsibility, or a manufacturing process. For example, the following figure shows a three-tier
alarm group hierarchy for a tank farm application.
Alarm groups are useful for filtering in alarm displays, alarm printers, and acknowledgment scripts.
Every tag is associated with an alarm group. By default, tags are assigned to main $System group.
You can create a hierarchy of additional alarm groups under the $System group, up to a maximum
of 32 levels.
You create alarm groups and associate tags with them while you are defining your tags in the
Tagname Dictionary.
Critical: 1-249 .
Major: 250-499
Minor: 500-749
Informational: 750-999
Wonderware Training
Section 1 – InTouch Tagname Alarm Configuration 5-5
Alarm Annunciation
InTouch provides numerous ways to provide operator notification, and to annunciate that an alarm
has occurred. InTouch provides system tags, alarm groups, tagname dotfields, script functions,
symbol properties, animation links, and popup windows – any or all of which can be used to
monitor and annunciate alarm conditions. By leveraging ArchestrA symbols, script functions and
animations in nearly infinite number of possibilities to alert Operators can be achieved.
Alarm Dotfields
You can use alarm dotfields to dynamically manage alarm conditions. Many of these dotfields are
accessible using I/O, expressions, and scripts. Through I/O access, you can monitor and control a
specific tag’s alarm information using other Windows applications, such as Excel, or
WindowViewer running on a remote node.
To access dotfields associated with a tag, use this syntax:
tag.dotfield
For example, if you want to allow runtime changes to the HiHi alarm limit on a tag named
Analog_tag, you can create an Analog - User Input animation link to a button and enter
Analog_tag.HiHiLimit as the expression in the link’s dialog box. During runtime, the operator
simply clicks the button and types in a new value for the HiHi alarm limit assigned to the
Analog_tag.
The following list represents some frequently used alarm dotfields.
Alarm Inhibition
Alarms can be prevented from annunciation such as appearing in the Alarm Client using Alarm
Inhibition Alarms. For example, an Alarm Group named Production1 can have all of its Hi and HiHi
alarms inhibited. Inhibition requires a discrete tag be created and linked to the inhibition field of a
tag or group.
In runtime, when this discrete tag is set to 1, all of the alarm states the inhibition tag was linked to,
are inhibited. For each distinct inhibition, additional discrete tags must be created and linked.
Alarm inhibition can be hidden from the Alarm Client display while still being tracked and recorded.
Alarm border animation also shows an indicator icon at the top-left corner of the border. Alarm
severity appears within the indicator icon as a number from 1 to 4. The indicator icon can be
shown or hidden as an option of Alarm Border animation and can be configured from the
ArchestrA IDE.
Alarm border animation can be applied to all types of symbols except embedded symbols and
nested groups. Alarm border animation can also be applied to graphic elements and group
elements.
Wonderware Training
Section 1 – InTouch Tagname Alarm Configuration 5-7
The alarm value returns to normal and the user acknowledges the alarm: Alarm Border
animation no longer appears around a symbol
The user suppresses an alarm: Alarm Border animation remains around the symbol in a
Suppressed visual style; however, an alarm indicator icon does not appear for a
Suppressed state
Note: Alarm Border animation is not used for alarms in an inhibited or a shelved state.
If a new alarm condition occurs when Alarm Border animation appears around a symbol,
the animation updates to show the new alarm state
In the case of aggregation alarms, Alarm Border animation shows the highest current
alarm state
Alarm Border animations can be configured by selecting Alarm Border from the list of
Visualization animations. The Alarm Border pane contains mutually exclusive fields to set the
referenced attributes for aggregate or individual alarms.
For aggregation alarms, users specify Alarm Border animation by entering an attribute or object
name in the Use Standard Alarm-Urgency References field of the Alarm Border pane. The
selected object attributes map to the following aggregation alarm attributes:
AlarmMostUrgentAcked: Indicates the acknowledgment status (True/False) of the
highest priority current alarm
AlarmMostUrgentInAlarm: Indicates the InAlarm status (True/False) of the highest
priority current alarm
AlarmMostUrgentMode: Indicates the mode (Enabled/Silenced/Disabled) of the highest
priority current alarm
AlarmMostUrgentSeverity: Indicates the severity as an integer (1-4) of the highest
priority current alarm; if no alarms are in an InAlarm state or waiting to be acknowledged,
the value is 0
To set Alarm Border animation for individual alarms, users specify references to the following
alarm attributes or tags:
InAlarm attribute
Acked attribute
Mode attribute
Severity attribute
Alarm Border animation subscribes to these attributes. Based on the alarm state of these
attributes, Alarm Border animation is applied to the graphic element in runtime.
Wonderware Training
Section 1 – InTouch Tagname Alarm Configuration 5-9
Wonderware Training
Lab 11 – Configuring InTouch Alarms 5-11
Introduction
In this lab, you will configure alarm limits for InTouch tags. Then, you will use the Situational
Awareness Wizard Options to enable alarm limit indicators, and an alarm border animation for the
SA_Meters symbol.
Objectives
Upon completion to this lab, you will be able to:
Define alarm limits for an Analog tag
Define a Discrete alarm for a Discrete tag
Enable advanced settings on the SA_Meters symbol including Alarm Limits and Alarm
Border
Set fixed values for AlarmMostUrgentMode and AlarmMostUrgentSeverity properties
Link InTouch alarm dotfields to custom properties
Identify Element Styles associated with an Alarm Border
Configure the Alarm Acknowledgment Model for a tagname
Create Alarm Groups and configure tags to use Alarm Groups
Configure an Inhibit tag and use it to inhibit alarms
4. Click OK.
Wonderware Training
Lab 11 – Configuring InTouch Alarms 5-13
In the Tagname Dictionary, the tag is displayed and the Alarms pane appears.
5. In the Alarms pane, check the LoLo and High check boxes.
6. In the LoLo Alarm Value field, enter 120, and in the High Alarm Value field, enter 150.
7. Click Save.
8. Repeat the previous steps to select the following tags, and enable the same alarm limits and
alarm values as follows:
Next, you will add an alarm border to the mixer temperature element.
10. In the ArchestrA Graphic Toolbox, double-click Mixer to open it for editing.
11. Click the Temperature element, and in the Properties pane, SymbolMode drop-down list,
select Advanced.
Additional properties appear.
AlarmHiLimitIndicator: True
AlarmLoLoLimitIndicator: True
AlarmBorder: True
Wonderware Training
Lab 11 – Configuring InTouch Alarms 5-15
Note: For tag-based designs, Alarm-Urgency Reference sources (Mode, Severity, and
Shelved) must be set to fixed values.
Test in Runtime
Next, you will test what you have configured in runtime.
18. Click Runtime.
19. Verify the alarm border displays when any temperature exceeds the alarm limits.
The alarm limit indicators are shown on the Temperature symbol where the HiLimit and the
LoLoLimit are positioned relative to the MinEU and MaxEU values defined for the tag.
20. Click Development!.
Wonderware Training
Lab 11 – Configuring InTouch Alarms 5-17
Wonderware Training
Lab 11 – Configuring InTouch Alarms 5-19
26. Click the Element Styles tab, and in the Element Style Overrides list, scroll down and select
AlarmBorder_Critical_RTN.
The line color and pattern of AlarmBorder_Critical_RTN are displayed.
The Line Pattern, Line Weight, and Line Color of the border are displayed.
The Preview area shows the appearance of alarm border configurations. In this case, it
displays the cross-hatch pattern, which looks like small evenly-spaced triangles.The settings
in the Outline tab can be configured to override default alarm border settings.
28. Click Cancel.
Wonderware Training
Lab 11 – Configuring InTouch Alarms 5-21
Test in Runtime
Next, you will test what you have configured in runtime.
29. Click Runtime.
30. In the Mixer window, notice the AlarmBorder_Critical_RTN is represented on the screen by
the cross-hatch pattern.
Note: Depending upon the PLCSim state, you may have to wait for up to 30 seconds to
notice this behavior.
Tagname: MixerGroup_Inhibit
Data Type: Memory Discrete
Wonderware Training
Lab 11 – Configuring InTouch Alarms 5-23
40. In the Value area to the right of the LoLo field, click the ellipsis button.
Wonderware Training
Lab 11 – Configuring InTouch Alarms 5-25
41. In the Select Tag dialog box, select the MixerGroup_Inhibit tag, and click OK.
MixerGroup_Inhibit is displayed in the LoLo field.
42. Repeat the previous steps to configure the High field with the same inhibit tag.
Wonderware Training
Lab 11 – Configuring InTouch Alarms 5-27
Notice the Group is $System and the ACK Model is set to Condition.
51. Click Close.
58. Click a blank space on the watch window, right-click and select Add Separator.
Wonderware Training
Lab 11 – Configuring InTouch Alarms 5-29
60. From the Dotfield Name list on the right, drag Alarm to the watch list.
$System.Alarm appears at the bottom of the watch list.
62. From the Dotfield Name list on the right, drag Alarm to the watch list.
Mixers.Alarm appears at the bottom of the watch list.
Note: The Mixer100_Temperature_PV value between 120 and 150 will cause the
Mixer100_Temperature_PV.Alarm value to show False.
68. In the Modify Discrete Value dialog box, click True, and click Apply.
69. Notice the following:
Mixers.Alarm and Mixer100_Temperature_PV.Alarm are set to False.
$System.Alarm is True because Tag_Discrete1.Alarm is true.
Tag_Discrete1 is not defined to use the Mixers alarm group.
The MixerGroup_Inhibit tag inhibits only tags using the Mixers alarm group.
$System.Alarm is True when any uninhibited alarm is true.
Mixers.Alarm is True when any temperature alarm is true.
70. In the Modify Discrete Value dialog box, click False, and click OK.
71. In the watch list, right-click, and select Save Watch List.
72. Close Tag Viewer.
73. Click Development!.
Wonderware Training
Section 2 – Live Alarms Management 5-31
When the Save User Queries and Filters option is selected, modifications made to queries or
filters at runtime are saved on a per user, and alarm control, instance to a .xml file. For example, a
saved query will save as UserQueryFilter_001.xml. Modifications are saved in the following
default directory:
C:\Users\<OS Login Name>\AppData\Local\Wonderware
The map between the Alarm Control instance and the above .xml file is saved in a map file,
InstancesMap.dat. Modified queries and filters will be available upon closing and restarting the
alarm control window or WindowViewer.
If you uncheck the Save User Queries and Filters option, updates made to queries and filters
during run-time will not be saved.
Note: When the Save User Queries and Filter option is checked, the Overwrite Design Time
Queries and Filters option is enabled and checked by default. When checked, this option
resolves naming conflicts between design-time queries and filters and run-time queries and filters
loaded from the .xml file. Naming conflicts will be resolved by overwriting the design time queries
and filters.
Wonderware Training
Section 2 – Live Alarms Management 5-33
Alarm Management
The Alarm Client is the primary tool used to manage alarms in your InTouch application.
Management of alarms involves identifying the when, where, and what of each alarm occurrence.
By interacting with the Alarm Client a user can perform management functions such as
acknowledging an alarm, hiding an alarm, or filtering the list of alarms to show a specific
occurrence of an alarm or event. Filters allow alarms to be displayed by group, tagname, or
priority.
Acknowledging Alarms
Every alarm in InTouch has two binary states. The first state is in alarm or not. The second is
acknowledged or not. These two binary states form a simple four-part truth table. The Alarm Client
allows you to manage this by displaying alarms in red, white, and rose colors. The fourth state is
when the alarm disappears from the Alarm Client.
When an alarm is first triggered it is both in alarm and unacknowledged. This state is named
UNACK_ALM. Before the problem that caused the alarm is resolved an operator can
acknowledge the alarm and take action to resolve the cause. This changes the state of the alarm
from UNACK_ALM to ACK_ALM. To acknowledge an alarm using the Alarm Client, the operator
must right-click the row of the alarm and chose Ack Selected. This causes a dialog box to appear
in which the operator must enter an alarm comment in order to acknowledged the alarm.
Once the cause of the alarm has been resolved an acknowledged alarm will disappear form the
Alarm Client. It is also possible that an alarm will return to normal before a user has time to
acknowledge it. This is named UNACK_RTN. An alarm in this state will remain visible in the Alarm
Client until it is acknowledged. In all cases an alarm must be both acknowledged and returned to
normal for it to disappear from the Alarm Client.
The User Input animation allows you to create a prompt message that appears for the user. The
resulting dialog box presents a list of choices that they can select from. You can use these choices
to set a reference for an InTouch tag. The User Input animation supports encryption to protect the
characters which are typed from observation from an onlooker and supports reflecting the input
selected back to the graphic or button through visual presentation.
Wonderware Training
Lab 12 – Visualizing and Acknowledging Live Alarms 5-35
Introduction
In this lab, you will create a symbol, and embed and configure a .NET Alarm Client. Then you will
use the Alarm Client to visualize and acknowledge current alarms at runtime.
Objectives
Upon completion of this lab, you will be able to:
Configure the .NET Alarm Client for current alarms
Visualize alarms using the .NET Alarm Client
Acknowledge alarms using the .NET Alarm Client
Configure a User Input animation
Wonderware Training
Lab 12 – Visualizing and Acknowledging Live Alarms 5-37
The Alarm Mode configuration uses a valid default for InTouch HMI applications. You will
manipulate the Alarm Query later in this lab.
6. In the Animations pane, select Column Details.
7. In the Column Details details animations pane, Column Details list, uncheck the User1
check box.
In the grid preview below the Column Details list, the User1 column has been removed.
8. In the Column Details animations pane, Column Details list, select Name.
Wonderware Training
Lab 12 – Visualizing and Acknowledging Live Alarms 5-39
10. With Tag selected, click the up arrow button until Tag appears below User1.
Wonderware Training
Lab 12 – Visualizing and Acknowledging Live Alarms 5-41
12. In the Run-Time Behavior animations pane, Show Context Menu list, uncheck the check
boxes next to the following menu items:
Ack Others
Shelve Selected
Shelve Others
Unshelve Selected
Unshelve Others
Hide Selected
Hide Others
Hidden
Sort
Queries and Filters
Freeze
Wonderware Training
Lab 12 – Visualizing and Acknowledging Live Alarms 5-43
15. On the canvas, draw a button next to the lower left corner of LiveAlarms.
23. In the Values area, True, 1, On field, on the drop-down list, select Intensity4.
24. In the False, 0, Off field, uncheck the Element Style check box.
Wonderware Training
Lab 12 – Visualizing and Acknowledging Live Alarms 5-45
Wonderware Training
Lab 12 – Visualizing and Acknowledging Live Alarms 5-47
36. In the Pushbutton animations pane, Value1 field, replace $System with Mixers.
43. Adjust the size of the button so the whole label is displayed.
Wonderware Training
Lab 12 – Visualizing and Acknowledging Live Alarms 5-49
Next, you will create a new button instead of duplicating the existing button so that you do not have
to delete animations inherited from the button that was created previously.
51. Create a new button and place it to the right of DiscreteAlarmTest.
52. In the Properties pane, name the button AckAll.
53. In the Text field, enter Ack All.
54. On the ElementStyle drop-down list, select Intensity1.
Wonderware Training
Lab 12 – Visualizing and Acknowledging Live Alarms 5-51
56. In the User Input animations pane, configure the User Input animation as follows:
States: Boolean
Reference
Boolean: InTouch:$System.Ack
Message to User: Are you sure you want to acknowledge ALL alarms?
Prompt
True Message: Yes
False Message: No
Interaction
Input Only: checked
58. Adjust the height of LiveAlarms to approximately half the original height.
59. Adjust the width of the LiveAlarms element to fit the width of the buttons.
Wonderware Training
Lab 12 – Visualizing and Acknowledging Live Alarms 5-53
Notice the Alarm Client does not fill the entire window. We will modify this next.
62. In the Properties pane, MaintainAspectRatio property, set the value to False.
The CurrentAlarms symbol is stretched to fill the entire frame window.
Note: You may have to scroll down to view the Tag_Discrete1 record.
Wonderware Training
Lab 12 – Visualizing and Acknowledging Live Alarms 5-55
Finally, you will set Tag_Discrete1 to False, which will return to normal and cause Tag_Discrete1
to disappear from the Alarm Client.
69. Click the Discrete Alarm Test button.
The Tag_Discrete1 record no longer appears in the list.
70. Open Tag Viewer, and ensure the My Watch List file is loaded.
71. In the Alarms watch list, double-click MixerGroup_Inhibit.
72. In the Modify Discrete Value dialog box, click True, and click OK.
In the watch list the MixerGroup_Inhibit tag is set to True.
73. Close Tag Viewer.
74. Click the Discrete Alarm Test button to enable it.
The Tag_Discrete1 tag is the only alarm displayed in the Alarm Client because all of the Mixer
tags have been inhibited.
75. In the Alarm Client, click the Tag_Discrete1 record to select it.
76. Right-click the Tag_Discrete1 record.
After a moment the context menu appears.
77. Click Ack Selected.
Wonderware Training
Section 3 – Historical Alarms Management 5-57
Overview
Historical alarms and events are managed in InTouch with a few utilities. In this section, event
configuration, historical alarm configuration, and the use of the alarm client for visualizing alarms
and events are discussed. Alarms and events are recorded to a database and later extracted for
visualization. The tools which are used for these functions are discussed below.
Alarm DB Logger
The Alarm DB Logger is an alarm consumer that uses an alarm query to determine which alarms
will be logged to a database. These alarm queries are sent to the Alarm Manager which sends all
alarms matching the query to the Alarm DB Logger.
The Alarm DB Logger also has the ability to automatically reconnect. The Alarm DB Logger
reports any errors to the ArchestrA Logger which can be viewed in the System Platform
Management Console (SMC).
The Alarm DB Logger Manager can also be used to monitor the Alarm DB Logger smart cache,
which represents the in-memory buffer used to hold alarm records. The smart cache holds alarms
retrieved from the Alarm Manager until these are logged to the database. As records are written
the count is decremented. Most of the time the count will show 0 unless a large number of alarms
is sent at one time.
Unwritten alarm records are buffered in the smart cache when the SQL Server connection is down
or when the alarms come at a rate faster than the logging rate of the Alarm DB Logger, which, by
default, is 10 records per second.
The Alarm DB Logger Manager utility can be launched from a shortcut in the WindowMaker Tools
pane Applications toolset, or from the Start menu.
The Alarm DB Logger Manager provides you with the ability to:
Run the application
Select the database connection type
Create the database and necessary SQL tables in the database
Delete the alarm database
Specify the alarm query
Select the logging mode – Detailed or Consolidated
Enable logging of events
Set performance tuning parameter
Store settings in the registry
Wonderware Training
Section 3 – Historical Alarms Management 5-59
Before you begin using the Alarm DB Logger, you must use the Alarm DB Logger Manager to
connect to MSSQL by configuring the node where SQL is running, setup login authentication
information, create a database (which automatically creates the necessary tables, views, and
stored procedures), test your database connection, delete the database if necessary, configure an
alarm query and the logging mode, and configure other settings, such as whether to log events
and the rate of logging.
Wonderware Training
Lab 13 – Visualizing and Filtering Historical Alarms and Events 5-61
Introduction
In this lab, you will use the Alarm DB Logger Manager to configure the Alarm DB Logger to record
historical alarms and events in a database. You will then duplicate the CurrentAlarms symbol
created in a previous lab and configure the duplicate to connect to a database and retrieve
historical alarms and events.
Objectives
Upon completion of the lab, you will be able to:
Configure a tag to log events
Configure and start the Alarm DB Logger
Configure a .NET Alarm Client for historical alarms and events
Construct Queries and Filters in both design time and runtime
Enable and disable Queries and Filters to sort alarm records in the Alarm Client in runtime
5. Click Close.
6. Click Runtime.
This will start WindowViewer and generate alarms which are needed for the remainder of this
lab.
7. Click Development!.
Wonderware Training
Lab 13 – Visualizing and Filtering Historical Alarms and Events 5-63
9. Click Settings.
The Alarm DB Logger Manager - Configuration dialog box appears.
10. In the SQL Server/MSDE area, Authentication drop-down list, verify Windows
Authentication is selected.
Notice the User Info area is now grayed out because User Info fields are only used when
using SQL Server Authentication.
11. In the Server Name field, enter your Engineering node name.
12. In the Database name field, ensure the default WWALMDB is entered.
13. Click Create.
A Success message appears.
Wonderware Training
Lab 13 – Visualizing and Filtering Historical Alarms and Events 5-65
The Alarm DB Logger Manager fills the smart cache first with records that match the
\InTouch!$System (all alarms) alarm query. Then, at a rate of 10 per second, it writes these
alarms and events into the database until the smart cache is empty. As new alarms occur
these are written to the WWALMDB database.
19. Close the Alarm DB Logger Manager dialog box.
The Alarm DB Logger (wwalmlogger.exe) continues running and recording alarms even after
you close the Alarm DB Logger Manager.
Wonderware Training
Lab 13 – Visualizing and Filtering Historical Alarms and Events 5-67
27. In the Database Connectivity area, Authentication Mode drop-down list, ensure Windows
Integrated is selected.
Wonderware Training
Lab 13 – Visualizing and Filtering Historical Alarms and Events 5-69
28. In the Server Name field, enter your Engineering node name.
This is the same node name provided by your instructor earlier in this lab.
32. In the top-right corner of the Queries and Filters animations pane, click the Add new query
button.
Wonderware Training
Lab 13 – Visualizing and Filtering Historical Alarms and Events 5-71
35. Click the right arrow button to add State to the filter definition list.
36. In the filter definition list, select State.
Wonderware Training
Lab 13 – Visualizing and Filtering Historical Alarms and Events 5-73
39. In the name list, select Group, and then click the right arrow button to add it to the filter
definition list.
Wonderware Training
Lab 13 – Visualizing and Filtering Historical Alarms and Events 5-75
45. Click the Add new query button, and in the Query or Filter Name field, enter
Mixer100_Temperature_PV UNACK_RTN.
Operator: =
Value: UNACK_RTN
49. Add Tag to the filter definition list, select Tag, and configure the area to the right as follows:
Operator: =
Value: Mixer100_Temperature_PV
Wonderware Training
Lab 13 – Visualizing and Filtering Historical Alarms and Events 5-77
Wonderware Training
Lab 13 – Visualizing and Filtering Historical Alarms and Events 5-79
68. In the Current Alarms window, click the Discrete Alarm Test button two times.
After a moment, the Query and Filter Favorites dialog box appears.
Wonderware Training
Lab 13 – Visualizing and Filtering Historical Alarms and Events 5-81
76. Use Tag Viewer to set MixerGroup_Inhibit to False, and then close Tag Viewer.
Wonderware Training
Lab 13 – Visualizing and Filtering Historical Alarms and Events 5-83
Next, you will filter the historical alarm client to show only events. This is done using the Class
filter. In an earlier lab, you disabled the Class column. However, this column is not necessary
because the brown color indicates an Event record.
84. In the Historical Alarms and Events window, right-click the HistoricalAlarmsEvents
symbol, and select Queries and Filters.
85. Click the Add new filter button.
Wonderware Training
Lab 13 – Visualizing and Filtering Historical Alarms and Events 5-85
Next, you will verify that the changes being made in Tag Viewer are being logged.
91. In the Query and Filter Favorites dialog box, check the Default and Events check boxes.
Finally, you will use a runtime filter to show alarm duration records that match a specific time
window.
93. In the Historical Alarms and Events window, right-click the HistoricalAlarmsEvents
symbol, and select Queries and Filters.
94. Uncheck the Events check box.
95. Click OK.
This restores the default query, which includes both alarm and event history.
96. Click the AlarmDuration column header twice to sort the list.
Notice the non-blank entries are sorted to the top of the list.
Wonderware Training
Lab 13 – Visualizing and Filtering Historical Alarms and Events 5-87
97. In the AlarmDuration column header, click the runtime query filter icon.
99. In the Custom Filter dialog box, to the right of Alarm Duration, click the drop-down arrow,
and select > Greater than.
102.Click OK.
Only records with an alarm duration of 30 seconds or greater are displayed.
103.Click Development!.
Wonderware Training
Module 6 – Data Logging and Trending
Section 1 – (Optional Path 1) InTouch History and Real-Time Trending 6-3
Lab 14 – Logging Historical Data Using InTouch History 6-7
Lab 15 – Trending Real-Time Data 6-27
Section 2 – (Optional Path 2) Using Historian with InTouch 6-39
Lab 16 – Logging Historical Data using Historian 6-43
Lab 17 – Building a Historian Client Trend Display 6-55
Section 3 – (Optional Path 1 and 2) Trend Pen 6-69
Lab 18 – Trending with Trend Pen 6-77
6-2 Module 6 – Data Logging and Trending
Module Objectives
Explain the differences between real-time and historical trends
Enable historical logging in InTouch
Use historical trend wizards
Examine historical data
Import InTouch tags into Historian
Verify imported tags are acquiring data to access in Historian
Use Historian Client Trend .NET control to retrieve data from Historian
Wonderware Training
Section 1 – (Optional Path 1) InTouch History and Real-Time Trending 6-3
Wonderware Training
Section 1 – (Optional Path 1) InTouch History and Real-Time Trending 6-5
Pens
The Pens animation allows you to add references to tags for plotting traces on the Trend Client
chart in real-time. Pen configuration induces a legend description, data range, width of the pen,
color of the pen, numerical formatting, and the historical source for backfill purposes.
You can connect a pen to an InTouch tagname using the InTouch:tagname syntax. You can also
reference tagname dotfields using InTouch:tagname.EngUnits. However, when specifying the
historical tag for backfill, the reference must not include the InTouch: prefix. You can browse
InTouch tags on the InTouch Browser tab in the Galaxy Browser. An ellipsis button is provided
in the UI for each location where a reference can be specified.
Use reference mode to specify a reference to an attribute or symbol property such as
Tank_001.PV. You can enclose static string values with double quotes (such as “Description:” or
“+Tank_001.Desc”) with or without references in Reference mode. When you are in Reference
mode, you can also click the ellipsis button to the right of the box to show a selection tool such as
the Galaxy Browser or the Tag Picker.
For analog tag values options such as Min, Max, and Units can be specified using InTouch
dotfields. Discrete tags, also named Boolean, do not have definitions for Min, Max, or EngUnits.
For these data types you must specify the configuration as a static value by changing the input
mode toggle switch to static text next to each field where a value will be entered.
Wonderware Training
Lab 14 – Logging Historical Data Using InTouch History 6-7
Introduction
In this lab, you will configure the application to begin historical logging. Then, you will configure the
tags that will log data. Next, you will create a window that will contain the historical trend wizards.
Then, you will test the window in runtime.
Objectives
Upon completion of this lab, you will be able to:
Enable historical logging
Configure a tag for log data
Build a window using historical trend wizards
Wonderware Training
Lab 14 – Logging Historical Data Using InTouch History 6-9
4. Select the Store Log Files in Specific Directory option, and enter C:\Training.
5. Click OK.
8. Click Save.
9. Repeat the previous steps to check the Log Data check box for the following tags:
Mixer100_Level_PV
Mixer100_Temperature_PV
10. Close the Tagname Dictionary.
Wonderware Training
Lab 14 – Logging Historical Data Using InTouch History 6-11
17. Change the Show Window animation link to show only the InTouch History window.
Wonderware Training
Lab 14 – Logging Historical Data Using InTouch History 6-13
23. Double-click Hist Trend w/Scooter and Scale to configure the trend.
The Historical Trend Chart Wizard dialog box appears.
24. Click Suggest.
Pen 2: Mixer100_Level_PV
Pen 3: Mixer100_Temperature_PV
Wonderware Training
Lab 14 – Logging Historical Data Using InTouch History 6-15
33. In the left pane, select Trends, and in the right pane, select Trend Zoom/Pan Panel.
The HistTrend tag is used to communicate between the wizards, therefore the tagname must
be the same.
Wonderware Training
Lab 14 – Logging Historical Data Using InTouch History 6-17
40. Reposition and resize the wizards to fit the height of the window.
Your screen will look similar to the following image.
44. Place the Trend Pen Legend to the right of the chart.
The remaining settings for the first legend are already correct for the Pen Number 1
configuration.
Wonderware Training
Lab 14 – Logging Historical Data Using InTouch History 6-19
49. Duplicate the first legend, and place the duplicate below Pen Number 1.
54. Duplicate the second legend, and place the duplicate below Pen Number 2.
55. Double-click the duplicate, and in the Pen Number field, enter 3.
56. In the Colors area, Trend Pen option, click the box to the right and select yellow.
Wonderware Training
Lab 14 – Logging Historical Data Using InTouch History 6-21
59. In the History window, click the Update to Current Time button.
60. Slide the left scooter until it touches the left edge of the visible data in the chart.
Wonderware Training
Lab 14 – Logging Historical Data Using InTouch History 6-23
The legend values on the right are based on the location of the right scooter. If a scooter
crosses an empty area of the chart where no traces are shown, the word Unavail will appear
instead of values.
63. Click Zoom In, or Zoom Out, to view different levels of detail.
64. Click Development!.
68. Ensure InTouch Training Application is selected and click the DBLoad button.
Wonderware Training
Lab 14 – Logging Historical Data Using InTouch History 6-25
InTouch Application Manager closes and the CSV File to Load From dialog box appears.
70. In the Files list, select LogDataForMixers.csv.
Wonderware Training
Lab 15 – Trending Real-Time Data 6-27
Introduction
In this lab, you will create a real-time trend symbol and embed a .NET Trend Client control. You
will configure the Trend Client to display mixer tags in real-time. Additionally, you will connect the
Trend Client to InTouch history to backfill the chart from historical data.
Objectives
Upon completion of this lab, you will be able to:
Use a Trend Client to display real-time production data
Configure a Trend Client to display mixer process tags
Backfill a Trend Client with InTouch historical data
4. Click OK.
5. Close the InTouch History window.
6. In the Menu window, add a duplicate navigation button labeled REALTime, with an animation
link to the REALTime window.
Wonderware Training
Lab 15 – Trending Real-Time Data 6-29
13. In the top-right corner of the Historical Sources animations pane, click the Add Row
button.
14. At the bottom of the Historical Sources animations pane, select the
InTouch Log History/LGH option.
15. In the Name field, enter InTouchHistory.
16. In the UNC Path field, enter c:\training.
Next, you will add one discrete InTouch tag pen and one analog InTouch tag pen to the Trend
Client.
17. In the Animations pane, select the Pens animation.
18. In the Pens animations pane, click the Add Row button.
19. In the Pen Name field, enter Level.
20. In the Expression or Reference field, enter InTouch:Mixer100_Level_PV.
Wonderware Training
Lab 15 – Trending Real-Time Data 6-31
21. In the Pen Details area, ensure that the Description field is set to the 'Static Text' mode,
as shown below.
23. In the Units field, switch to Expression or Reference mode, and enter
InTouch:Mixer100_Level_PV.EngUnits.
24. In the Min field, switch to Expression or Reference mode, and enter
InTouch:Mixer100_Level_PV.MinEU.
25. In the Max field, switch to Expression or Reference mode, and enter
InTouch:Mixer100_Level_PV.MaxEU.
26. In the Pen Options area, change the color to bright green.
27. Change the Width to 2.
28. In the Pen Options area, retain the default settings for all other options.
29. In the Historical area, ensure Source is 'Static Text' mode, and enter InTouchHistory.
30. Ensure Tag is 'Static Text' mode, and enter Mixer100_Level_PV.
Wonderware Training
Lab 15 – Trending Real-Time Data 6-33
31. Add another pen to the Pens animation, and configure it as follows:
Note: Discrete InTouch tags, such as the Mixer100_Agitator_PV, do not have Engineering
Units. To display a clean square waveform on the Trend Client that fills the full height of the
chart, you will provide static values of 0 for Min and 1 for Max.
Pen Options
Color: Bright Red
Width: 2
Historical
Source: InTouchHistory
Tag: Mixer100_Agitator_PV
33. In the Appearance animations pane, change the Background color to black.
34. Change Highlight color to white.
35. Change Width to 3.
36. On the Style drop-down list, select the last option.
Wonderware Training
Lab 15 – Trending Real-Time Data 6-35
38. In the Options animations pane, check the Show pen selector check box.
Wonderware Training
Lab 15 – Trending Real-Time Data 6-37
The Agitator pen is selected by default in the pen selector (legend). The Allow highlight pen
option that was selected in the Appearance animation makes the Agitator pen a thick white
line on the trend.
44. Select the Level pen.
Notice in the rising slope of the level at 60% full, a small, flat line indicating the moment when
ingredient 1 and ingredient 2 are transitioning. During this 4-second window, the level remains
steady in the mixer. You can also see the agitator only runs when the mixer is full.
45. Click Development!.
46. In WindowMaker, close the REALTime window.
Wonderware Training
Section 2 – (Optional Path 2) Using Historian with InTouch 6-39
Wonderware Training
Section 2 – (Optional Path 2) Using Historian with InTouch 6-41
The Configuration Editor can be used to add tags which will be historized, delete tags, and
modify the definitions of tags.
Wonderware Training
Lab 16 – Logging Historical Data using Historian 6-43
Introduction
In this lab, you will use the Historian Tag Importer Wizard from the SMC to import tags from the
InTouch Training Application. Once the tags are imported, you will commit pending changes and
verify data acquisition is successful.
Objectives
Upon completion of this lab, you will be able to:
Use the SMC to verify that Historian Server is running
Use the SMC to import tags from an InTouch application
Use the SMC to commit pending changes
Verify imported tags are acquiring data
Wonderware Training
Lab 16 – Logging Historical Data using Historian 6-45
9. Click Next.
The Tag Importer Wizard - Already Imported Nodes dialog box appears, indicating that no
tags from an InTouch application have been imported.
Wonderware Training
Lab 16 – Logging Historical Data using Historian 6-47
14. Since there will not be any duplicate tags during the import, check the Bypass Uniqueness
String check box.
A Wonderware Historian message appears warning you that duplicate tagnames will not be
imported.
The Tag Importer Wizard - Tag Duplicates dialog box shows the Bypass Uniqueness
String check box checked.
Wonderware Training
Lab 16 – Logging Historical Data using Historian 6-49
18. In the Logged Only for Category area, click the Topics button.
22. Click OK to close the Tag Importer - Select Topics dialog box.
Wonderware Training
Lab 16 – Logging Historical Data using Historian 6-51
23. On the The Tag Importer Wizard - Filter Tags dialog box, click Next.
The Tag Importer Wizard - Tag Storage dialog box appears.
The Tag Importer Status dialog box appears, displaying information about the imported tags.
The import operation stages the tags you have imported in a holding area.
26. Wait until the status of the import operation shows Import Completed Successfully.
Wonderware Training
Lab 16 – Logging Historical Data using Historian 6-53
In the Tags column, the window shows the total number of tags being received.
36. Close the SMC.
37. In WindowViewer, click Development!.
Wonderware Training
Lab 17 – Building a Historian Client Trend Display 6-55
Introduction
In this lab, you will use the Historian Client Trend .NET control to create a display for tag data
from Historian Server in a trend chart.
Objectives
Upon completion of this lab, you will be able to:
Use the Historian Client Trend .NET control in InTouch
Import a .NET client control library file using WindowMaker
Use Live Mode to continuously refresh the trend with current data
Wonderware Training
Lab 17 – Building a Historian Client Trend Display 6-57
5. Click Close.
Wonderware Training
Lab 17 – Building a Historian Client Trend Display 6-59
19. In the Menu window, add a Trend navigation button, with an animation link to open the Trend
window.
Test in Runtime
Next, you will view the historian tag data in the trend in runtime.
20. Click Runtime.
The Trend window appears with an empty chart.
Wonderware Training
Lab 17 – Building a Historian Client Trend Display 6-61
22. In the Server field, enter the name of your Historian Server (Engineering node).
Note: Your instructor will provide the name of your Historian Server (Engineering node).
Note: If special instructions are required, your instructor will provide this information.
Wonderware Training
Lab 17 – Building a Historian Client Trend Display 6-63
The Server list displays your Historian Server (Engineering node) name. The font face will be
normal text if a successful connection was made to your Historian Server. The font will be
italicized if trend was unable to connect successfully to your Historian Server.
26. In the Tag Picker, Servers list, select the Historian Server (Engineering node) name.
The list of tags available from the Historian Server appears in the Tags List.
Wonderware Training
Lab 17 – Building a Historian Client Trend Display 6-65
29. In the Tag Picker, drag the following tags onto the chart.
Mixer100_Level_PV
Mixer100_Temperature_PV
All three tags are now plotted on the chart.
Wonderware Training
Lab 17 – Building a Historian Client Trend Display 6-67
Wonderware Training
Section 3 – (Optional Path 1 and 2) Trend Pen 6-69
A Step Line plot draws a horizontal line from a trend data point to the time of the next point on the
trend’s X-axis, and then draws a vertical line to the data point. A Step Line plot is the default for a
Trend Pen.
4. Release the left mouse key after sizing the rectangle to the height and width that you want to
represent as the trend area.
The Trend Pen dialog box appears when the mouse key is released. You can also show the
Trend Pen dialog box by double-clicking on the Trend Pen graphic or selecting Edit
Animations from the Special menu.
Wonderware Training
Section 3 – (Optional Path 1 and 2) Trend Pen 6-71
9. Select Auto-Range or Clip out of Range Values for the scaling method to place process
values on a trend line.
If Auto-Range is selected, the Min Range and Max Range fields are disabled. The Y-axis of
the trend line is automatically adjusted to show the full range of trend values within the upper
and lower boundaries of the Trend Pen graphic.
If Clip out of Range Values is selected, the Min Range and Max Range fields are enabled.
Min Range and Max Range set the lower and upper limits of the trend’s Y-axis value range.
Both fields can be set to constants, external references, or custom properties.
When a value exceeds the trend’s minimum or maximum limits using Clip out of Range
Values, the trend line is truncated at the limit of the value range and appears as a horizontal
line for the period when the process value is out of trend’s value range.
10. From Plot Type, select Step Line or Line as the type of trend plot.
A Step Line plot draws a horizontal line from a trend data point to the time of the next data
point on the trend’s X-axis, and then draws a vertical line to the data point.
A Line plot draws a line directly to each successive point within the trend period.
The following properties are typically modified during run time to change the visual and functional
characteristics of a Trend Pen.
Wonderware Training
Section 3 – (Optional Path 1 and 2) Trend Pen 6-73
MinValue Property
During run time, the value of the MinValue property can be modified to change the minimum
measured value shown by a trend. During run time, MinValue can be a read/write or a read only
property based on the value assigned to the Trend Pen’s Y Axis Range option during design time.
When Y Axis Range is set to Auto-Range during design time:
The minimum measured value shown by a trend is set to the minimum value of data
received from the Historian or from current data during the trend period. MinValue is read
only.
When Y Axis Range is set to Clip out of range values during design time:
The minimum measured value shown by a trend is set to a minimum limit set from the Min
Range option during design time.
MinValue is read/write and can be changed during run time. When MinValue is changed
during run time, the trend line is redrawn based on the values assigned to the MinValue
and MaxValue properties.
When the values assigned to MinValue and MaxValue properties are the same, the trend’s
Y Axis Range automatically changes to Auto-Range.
MaxValue Property
During run time, the value of the MaxValue property can be modified to change the maximum
measured value shown by a trend. During run time, MaxValue can be a read/write or a read only
property based on the value assigned to the Trend Pen’s Y Axis Range option during design time.
When Y Axis Range is set to Auto-Range during design time:
The maximum measured value shown by a trend is set to the maximum value of data
received from the Historian or from current data during the trend period. MaxValue is read
only.
When Y Axis Range is set to Clip out of range values during design time:
The maximum measured value shown by a trend is set to a maximum limit set from the
Max Range option during design time.
MaxValue is read/write and can be changed during run time. When MaxValue is changed
during run time, the trend line is redrawn based on the values assigned to the MinValue
and MaxValue properties.
When the values assigned to MinValue and MaxValue properties are the same, the trend’s
Y Axis Range automatically changes to Auto-Range.
StartTime Property
During run time, the value of the StartTime property can be modified to change the start time of a
trend period based on the value set to the Trend Pen Time Period during design time.
When Time Period is set to Fixed during design time:
The default value assigned to the StartTime property is the most recent time
WindowViewer was started. StartTime is read/write and can be changed during run time.
When the value of StartTime changes, the Trend Pen re-plots the trend using the new
StartTime value.
When Time Period is set to Moving during design time:
The value set to the EndTime property is the current system date and time. In Moving
mode, StartTime is read only.
EndTime Property
During run time, the value of the EndTime property can be modified to change the end time of a
trend period based on the value set to the Trend Pen Time Period during design time.
When Time Period is set to Fixed during design time:
The default value assigned to the EndTime property is the end time set during design time.
EndTime is read/write and can be changed during run time. When the value of EndTime
changes, the Trend Pen re-plots the trend using the new EndTime value.
When Time Period is set to Moving during design time:
The value set to the EndTime property is the current system date and time. EndTime is
read only.
PlotType Property
During run time, the value of the PlotType property can be modified to change the type of trend
plot.
When PlotType is 0, the Trend Pen plot type is Step Line. The default.
When PlotType is 1, the Trend Pen plot type is Line.
The value of PlotType is ignored if the value is neither 0 nor 1.
When the value of PlotType changes in run time, trend data is retrieved again before
drawing the trend.
TimeMode Property
During run time, the value of the TimeMode property can be modified to change the type of trend
time period.
When TimeMode is 0, the trend time period mode is Moving. The end time of the trend is
the current system time. The default.
When TimeMode is 1, the trend time period mode is Fixed. The start time of the trend is
the most recent time WindowViewer started.
The value of TimeMode is ignored if the value is neither 0 nor 1.
When the time period changes from Moving to Fixed during run time, the trend’s start time and end
time remain the same before switching, and the data remains as well. When the time period
changes from Fixed to Moving during run time, data is retrieved again before drawing the trend.
The trend’s start and end times are adjusted automatically by Moving mode.
FillTrend Property
During run time, you can use the FillTrend property to change the appearance of the area below
the trend pen curve.
The FillTrend property can also be modified using scripts. For example
TrendPen6.FillTrend = not TrendPen6.FillTrend;
The Fill Property in Fill Style animation, Element Style animation, or Element Style will now apply
to the FillTrend property according to the general element style precedent rules.
Wonderware Training
Section 3 – (Optional Path 1 and 2) Trend Pen 6-75
Note: The FillTrend property may be enabled in design time or runtime. However, the color used
to fill the trend defaults to white unless a different color has been selected at design time.
SA_Trend_SinglePen Symbol
The SA_Trend_SinglePen symbol shows a single measured value as a trend line over a specified
period. The symbol includes a Type Wizard Option to show a trend line as a Tail trend by itself
without a trend client area or as a Simple trend that includes more visual elements.
The symbol can show real time and IDAS (IndustrialSQL Data Acquisition Service) historical data
when the reference values of trend pens are set to ArchestrA object attributes.
Note: The SA_TrendSinglePen symbol shows alarm data collected only from ArchestrA objects.
The symbol includes a set of run time controls to show additional data about the measured value
in a floating tooltip or along the Y axis of the trend. Operators can also change the length of the
trend period while the application is running by selecting another trend period from a control.
The symbol includes a Wizard Option to insert a meter at either side of the trend with the trend line
showing a meter's measured value over the trend period. The trend can show the typical symbol
components of meter symbols with an optimal value range, a setpoint, and tracker line shown in
the trend client area. The meter is similar to the general purpose SA_Meters symbol with an option
to select from eight different types of meters.
SA_Trend_MultiPen Symbol
The SA_Trend_MultiPen symbol supports up to four concurrent trend lines that show measured
values over a specified trend period. The symbol provides Wizard Options to change the trend plot
type, the mode of the trend period, and how trend lines are drawn when their measured values
exceed the range shown on the Y axis of the trend grid.
The symbol can show real time and historical data when the trend pens are set to reference values
of ArchestrA object attributes. The trend can only show real-time data when the pens are set to
InTouch tags.
The symbol includes a set of run time controls for operators to select a pen to show additional data
about its measured value in a floating tooltip or along the Y axis of the trend. Operators can also
change the length of the trend period while the application is running by selecting another trend
period from a control.
Each pen appears as a graphic square in a pen selector panel above the trend grid. The border
color of each pen square matches the color of the pen line shown in the trend. When a pen's
measured value goes into an alarm state, Alarm Border animation appears around the pen
square.
Wonderware Training
Lab 18 – Trending with Trend Pen 6-77
Introduction
In this lab, you will create a Trend Pen element to show the recent history from a field device.
This lab is divided into three parts. The first part is common and will be performed by all students.
Option 1 is for students who have completed Lab 14, “Logging Historical Data Using InTouch
History”. In this part, you will modify the Mixer symbol by adding a Trend Pen for the Temperature
meter which relies on InTouch History to backfill the trend.
Option 2 is for students who have completed Lab 16, “Logging Historical Data using Historian”. In
this part, you will modify the Mixer symbol by adding a Trend Pen for the Level meter which relies
on data from Historian to backfill the trend.
Objectives
Upon completion of this lab, you will be able to:
Use the Trend Pen element to display historical data
Use fixed width and height for a symbol
Wonderware Training
Lab 18 – Trending with Trend Pen 6-79
The Temperature meter is now positioned on the right side of the tank.
7. On the Elements list, with Temperature selected, hold down the Ctrl key and click on Level
and Agitator to add them to the selection.
8. With the Temperature, Level and Agitator elements selected, on the toolbar, click Make
Horizontal Spacing Equal.
Wonderware Training
Lab 18 – Trending with Trend Pen 6-81
The canvas is resized to the fixed width and height, and handles appear for resizing.
13. Drag to resize the canvas to provide one blank grid space on the bottom and right side of the
symbol.
The canvas size determines how much white space is included with the symbol to maintain its
aspect ratio in frame windows and at runtime. This helps when displaying a symbol with a
different shape than the frame window hosting it.
14. Save and close the Mixer symbol.
15. In WindowMaker, open the Mixer window.
The Frame window displays the resized symbol.
Data
Name Default Value Visibility
Type
TempPen_PV Float InTouch:Mixer100_Temperature_PV Public
TempPen_Min Float InTouch:Mixer100_Temperature_PV.MinEU Public
TempPen_Max Float InTouch:Mixer100_Temperature_PV.MaxEU Public
18. In the Symbol Editor, from the Zoom drop-down list, select 300%.
Wonderware Training
Lab 18 – Trending with Trend Pen 6-83
20. In the space between Level and Temperature, click and drag to the right and down to draw a
trend pen on the canvas.
Upon release of the mouse, the Edit Animations dialog box opens with the Trend Pen
animation showing.
21. In the Trend Pen details pane, enter the details as follows:
Details Value
Reference TempPen_PV
Historical Source InTouch Log History/LGH
UNC Path c:\training
Time Period Moving
Duration 5
Y Axis Range Clip out of range values
Min Range TempPen_Min
Max Range TempPen_Max
Plot Type Line
Wonderware Training
Lab 18 – Trending with Trend Pen 6-85
Note: If necessary, disable Snap to Grid to accurately align the Trend Pen.
Test in Runtime
Next, you will test the Trend Pen in runtime.
28. In WindowMaker, click Runtime.
The trend will backfill and display the last five minutes of data, and then continuously plot in
real time.
Wonderware Training
Lab 18 – Trending with Trend Pen 6-87
Option 2: Add a Trend Pen to the Level Meter for Historian Data
This option is for students who have completed Lab 16, “Logging Historical Data using Historian”.
Next, you will add a Trend Pen to compliment the Level Meter. The Trend Pen will be configured to
backfill using Historian data.
30. In WindowMaker, in the ArchestrA Graphic Toolbox, open the Mixer symbol for editing.
31. Right-click the canvas and select Custom Properties and create the following:
Data
Name Default Value Visibility
Type
LevelPen_PV Float InTouch:Mixer100_Level_PV Public
LevelPen_Min Float InTouch:Mixer100_Level_PV.MinEU Public
LevelPen_Max Float InTouch:Mixer100_Level_PV.MaxEU Public
32. In the Symbol Editor, from the Zoom drop-down list, select 300%.
34. In the space between Agitator and Level, click and drag to the right and down to draw a trend
pen on the canvas.
Upon release of the mouse, the Edit Animations dialog box opens with the Trend Pen
animation showing.
Wonderware Training
Lab 18 – Trending with Trend Pen 6-89
35. In the Trend Pen details pane, enter the details as follows:
Details Value
Reference LevelPen_PV
Historical Source Historian
Historian Expression
Server Name <Historian Node Name>
(Instructor will provide)
Time Period Moving
Duration 5
Y Axis Range Clip out of range values
Min Range LevelPen_Min
Max Range LevelPen_Max
Plot Type Line
Wonderware Training
Module 7 – Introduction to QuickScript
Section 1 – Introduction to InTouch QuickScript 7-3
Lab 19 – Opening an Application with QuickScript 7-17
7-2 Module 7 – Introduction to QuickScript
Module Objectives
Introduce QuickScript
Describe InTouch scripting
Wonderware Training
Section 1 – Introduction to InTouch QuickScript 7-3
This section will provide an overview of the various InTouch QuickScript types, and describe the
features and functions that are unique to each QuickScript type. This section will also explain the
QuickScript Editor.
QuickScript
QuickScript is the name of the script language, and functionality used in the InTouch environment.
The actual script language is very similar to PLC languages like IEC611-31 and Structured Text.
InTouch QuickScript capabilities allow you to execute commands and logical operations based on
specified criteria being met. All InTouch QuickScripts are event driven, such as a data change, a
condition, a mouse click, or a timer. You can add conditional statements, loops, and local variables
to the basic scripts to create complex effects in your application.
QuickScript types include the following:
Application – Scripts linked to the entire application
Window – Scripts linked to a specific window
Key – Scripts linked to a specific key or key combination on the keyboard
Action – Scripts associated with an object linked to a Touch Link - Touch Pushbutton -
Action animation link
Data Change – Scripts linked to a tagname and/or tagname.field only
Condition – Scripts linked to a discrete tagname or expression
ActiveX Event – Scripts that execute ActiveX control events in runtime
QuickFunctions – Scripts you create that can be named from other InTouch QuickScripts
using CALL FunctionName(); or inside animation link expressions. QuickFunctions can
be either synchronous or asynchronous, while all other script types are synchronous only
Specific functions already configured to the proper syntax and format, are available from the script
dialog box and can be pasted with a single mouse click. Additional information about scripting
concepts and about creating and editing scripts is available in the application Help and in the
InTouch HMI Scripting and Logic Guide, available within your local installation of InTouch.
You can configure most script types to execute based on multiple conditions using script triggers.
For example, you can define a script to run when WindowViewer is started, and then periodically
at fixed intervals while WindowViewer is running. Each script type has one or more triggers.
The order in which scripts are processed is based on a complex set of variables as the InTouch
WindowViewer application’s QuickScript engine is not scan based, therefore, the order of
execution cannot be guaranteed. When using QuickScript, avoid building script dependencies
based on any perceived sequence, the sequence can change as well based on criteria beyond the
control of application designers.
For all InTouch While scripts (repeating at specified interval), the script will not execute the first
time until the period has elapsed. Additionally, InTouch is not based on a scan engine with
guaranteed interval, so the only guarantee is that the script will NOT execute faster than the
interval specified. Finally, WindowViewer will make every attempt possible to run scripts as fast as
the specified time, however, no script can run faster than the Tick Interval setting specified in
WindowViewer properties.
Global Scripts
The scope of execution (where the script lives) determines when or even if data from those scripts
tags or functions is available throughout the application. Global scope means no matter where an
operator has navigated within the application, these scripts continue executing in the background,
as needed, and make their results continuously available. Global scope script types are limited to
Application scripts, Data Change scripts, Condition scripts, Key scripts, and QuickFunctions.
Application Scripts
Application Scripts are linked to the entire InTouch application. These scripts execute one time
when the application is started or shut down. Or run continuously while WindowViewer is in
memory.
There are three types of Application Scripts:
On Startup – Executes once when the application is initially started up. Executes before
any window opens or any runtime initialization occurs. You cannot refer to ActiveX
methods, properties, or events in an On Startup script. I/O communications are initialized
after the application On Startup script executes. I/O tags or remote tagname references
cannot be referred to in an On Startup script.
While Running – Executes repeatedly at the specified frequency while the application is
running. When a While Running script is selected, the Every Msec field becomes active.
The field contains the number of milliseconds that must elapse before the script executes.
The While Running script will repeatedly execute no sooner than the specified frequency,
however, the script will execute as long as WindowViewer is running.
On Shutdown – Executes once when the application is closed. I/O tags and remote
tagname references will not update in an On Shutdown script. An On Shutdown script
cannot be used to startup other applications.
Condition Scripts
Condition scripts execute when a logical condition occurs. Condition scripts are linked to a discrete
tag or expression that equates to TRUE or FALSE. The condition can contain expressions of up to
1024 characters.
Since Condition scripts are executed based on a condition being met, you must specify the
condition (a discrete tag or Boolean expression) in the Condition field. The expression must
equate to a 1 (TRUE) or 0 (FALSE) result. For example, the following expression remains true for
1 minute out of every day, just prior to midnight.
$Hour == 23 AND $Minute == 59
There are four types of scripts that can be applied to a condition:
On False – Executes once when the condition transitions to false
While False – Executes repeatedly while the condition is false. Frequency of execution is
based upon the value of the Every msec field
On True – Executes once when the condition transitions to true
While True – Executes repeatedly while the condition is true. Frequency of execution is
based upon the value of the Every msec field
Both While True and While False scripts begin executing after the specified number of
milliseconds has elapsed. To cause immediate execution, create duplicate On True or On False
scripts. All four script types can be applied to the same condition.
Wonderware Training
Section 1 – Introduction to InTouch QuickScript 7-5
Key Scripts
Key scripts execute on a specific key or key combinations on the keyboard. They can be used to
create global keys for the application, such as returning to a main menu window, or logging off the
operator.
There are three types of Key scripts:
On Key Down – Executes once when the key is initially pressed
While Down – Executes repeatedly at the specified frequency while the key is held down.
When While Down is selected, the Every msec field is enabled. The field contains the
number of milliseconds that must elapse before the script executes
To execute the script immediately, create an identical On Key Down script. As long as the
condition or event for the While Down script is met, the script will repeatedly execute at the
specified frequency
On Key Up – Executes once when the key is released
If an action script on a window is assigned to a Key that is already used in a global Key script, the
local action script overrides the global Key script.
Local Scripts
The scope of execution for all other script types including Window scripts, Action scripts, ActiveX
scripts, and ArchestrA Symbol scripts are local execution only. Local scripts only run from an open
window. These scripts run when the operator takes a specific action on the window. When a
window closes all scripts on that window stop executing. Local window script functionality includes
Action, Window on Show, Window on Hide, Window While Showing, ArchestrA, and ActiveX
scripts.
Action Scripts
Action scripts are similar to Key scripts, except they are associated with an object linked to a
Touch Link – Touch Pushbutton – Action. They are executed when the operator clicks or
presses the object or button assigned to the link.
There are 13 types of Action scripts. But they can be broken down into four simple categories
based on a simple pointing device such as a three-button Mouse. For each of the three buttons,
there are four possible states: click, double-click, held-down, and released. This represents 12 of
the Touch Action script options. The last script type executes when the mouse hovers over the
object without clicking.
The following Action scripts execute once when the key or button is initially pressed.
On Left Click/Key Down
On Right Click
On Center Click
The following Action scripts execute repeatedly at the specified frequency while the key or button
is held down. When this is selected, the Every msec field is active. The field contains the number
of milliseconds that must elapse before the script executes:
While Left/Key Down
While Right Down
While Center Down
The following Action scripts execute once when the key or button is released:
On Left/Key Up
On Right Up
On Center Up
The following Action scripts execute when the mouse button is double-clicked. The key equivalent
feature disables when these are selected, since there is no keyboard equivalent for a mouse
button double-click action:
On Left Double-Click
On Right Double-Click
On Center Double-Click
The following Action scripts execute one time when the cursor rests over an object. The script
does not trigger until the After msec field value is exceeded, this helps avoid unintentional
triggering as the mouse is being moved around the screen, only deliberately coming to rest over
the object will trigger the script. After msec is the length of time the cursor must be over the object
before the script executes. The key equivalent feature is disabled when this condition type is
selected, since there is no keyboard equivalent for moving the mouse cursor over an object.
On Mouse Over
Wonderware Training
Section 1 – Introduction to InTouch QuickScript 7-7
Window Scripts
Window scripts function within a specific window.
There are three types of Window scripts:
On Show – Executes once when the window is initially opened
While Showing – Executes repeatedly at the specified frequency while the window is
showing. When While Showing is selected, the Every msec field becomes active. The
field contains the number of milliseconds that must elapse before the script executes. To
execute the script immediately, create an identical On Show script. As long as the
condition or event for the While Showing script is met, the script will repeatedly execute at
the specified frequency
On Hide – Executes once when the window is closed. A window that is covered or hidden
by other windows or whose x, y location is off the display is still active and running in
memory, even if the operator cannot see its contents
ActiveX Scripts
Many ActiveX controls have events for handling things like click, double-click, mouse down, and
key press. An ActiveX Event script tied to a specific event in an ActiveX control placed on an
window will execute when that event occurs. You may associate one ActiveX Event script to one
event in an ActiveX control. If an ActiveX script is written in a generic way so as to be reusable, it
may be used and called from more than one ActiveX control event.
Area Description
1 Toolbars
2 Condition definition area
The Condition Type box provides the available execution conditions for the type of script you
are writing.
3 Script text window
4 Command buttons
5 Built-in script function buttons
6 MEM OLE button
The MEM OLE button in the lower right corner only appears if the Manufacturing Engineering
Module (MEM) is installed with the InTouch HMI installation. Clicking this button allows you to
script with MEM.
Wonderware Training
Section 1 – Introduction to InTouch QuickScript 7-9
Element Color
Keywords Blue
Syntax highlighted while typing.
Comments (both single line and multi-line) Green
Syntax highlighted while typing.
Strings Purple
Syntax highlighted while typing.
Function names, numeric constants, Black
operators, semicolons, dim variables, alias
See descriptions for Attribute names and Reserved words.
variables, and so on
Attributes, InTouch Tags, Reference Strings Maroon, bold face
Reserved words Red, non-bold face
.NET type names Teal, non-bold face
Autocomplete Features
The InTouch script editor autocomplete incorporates several features for use while authoring
InTouch scripts. Autocomplete displays a context-sensitive list of options for script elements,
keywords, object and attribute names, and programmatic constructs. You can identify the context
from the icons displayed at the bottom of the autocomplete pop-up window. Autocomplete has the
following features:
Provides an autocomplete tag reference in a selectable list box.
Provides method parameter help in an autocomplete list box including context-specific
suggestions covering definitions, keywords, script elements, and programmatic
constructs.
Automatic word completion of tags, dotfields, methods, programmatic constructs, and
other script elements.
Press Ctrl+Space to display all available autocomplete options and variables for the selected
location in the script. Autocomplete represents each scripting element with a different icon. Icons
represent keywords, operators, Variables, tags, windows, and ActiveX instances.
Change Bars
As a visual reference for script changes in-progress, yellow change bars on the left margin of the
script text window indicate additions and line insertions and edits.
Tag Definition
You can enter a new tagname in the InTouch script editor, then press Ctrl+T or click Edit on the
main menu to define a tag. The Tagname Dictionary appears so you can complete the tagname
definition.
Wonderware Training
Section 1 – Introduction to InTouch QuickScript 7-11
Script Functions
A script function is a script which has been written and made available from the function list for
calling from other scripts. A script function may include arguments or parameters which must be
specified when the function is called. For example, the following shows a syntax for a function with
two parameters:
StringLeft( Text, Chars );
This example will select the number of characters specified in the Chars parameter from the left
side of the text parameter. If Text contained Mixer100_Temperature_PV, and Chars contained 8,
the StringLeft function would return Mixer100.
Some functions do not require parenthesis around the parameters or arguments. For example, the
Show function uses the following syntax:
Show “My Window”;
In this example “My Window” is a parameter required by the Show function. The Show function
opens a window at runtime.
Some functions return a result. When a function returns a result this must be captured in either a
tag or a local variable. Without assigning the return result, the script function will fail to validate and
the script will not save. Some functions which return a result can also be used in an animation
expression directly.
Function Help
To access help documentation for a script function, click the Help button in the script editor and
select the function you wish to look up. Help documentation for each function includes proper
syntax usage, details on each parameter, and examples of how to use the script function in the
script.
The simplest form of this conditional branching functionality is illustrated by the following example:
IF UnauthorizedAccess == 1 THEN
Show “Security Alert”;
ENDIF;
In the above script, a tagname named UnauthorizedAccess is evaluated and compared to a
numeric value of 1, and if it is found to be TRUE, the script will proceed to the statement Show
“Security Alert”; which will open a window named Security Alert.
If the tagname UnauthorizedAccess contained any value other than 1, even a value such as
1.0001 (which is not equal to 1), and then the system skips over the statement and ends after the
ENDIF; portion of the script. IF THEN ENDIF; is the most basic form of a decision making tool.
The following comparison operators are also valid for conditional expressions:
Wonderware Training
Section 1 – Introduction to InTouch QuickScript 7-13
Syntax
FOR LoopTag = StartExpression TO EndExpression [STEP ChangeExpression]
... statements or another FOR loop ...
NEXT;
StartExpression, EndExpression and ChangeExpression together define the
number of iterations.
StartExpression sets the start value of the loop range. EndExpression sets the
end value of the loop range.
STEP ChangeExpression optionally sets the value by which the loop tag is
incremented or decremented during each loop iteration; if you do not specify this, a default
of 1 is used.
When you execute a FOR loop, the InTouch HMI:
1. Sets LoopTag to the value of StartExpression.
2. Tests whether LoopTag is greater than EndExpression. If so, the InTouch HMI exits the
loop. (If ChangeExpression is negative, the InTouch HMI tests whether LoopTag is less
than EndExpression.)
3. Executes the statements within the loop.
4. Increments LoopTag by the value of ChangeExpression (1 unless otherwise specified).
5. Repeats steps 2 through 4.
Remember the following rules when working with FOR loops:
FOR loops can be nested. The maximum number of nesting levels depends on the
available memory and system resources.
For every FOR statement, there must be a closing NEXT statement. A NEXT statement
always applies to the nearest prior FOR statement on the same nesting level.
LoopTag must be a numeric tag (or local variable).
StartExpression, EndExpression and ChangeExpression must be valid
expressions that evaluate to a numeric result.
If ChangeExpression is positive, EndExpression must be greater than
StartExpression; if ChangeExpression is negative, StartExpression must be
greater than EndExpression. Otherwise, the loop does not start.
To exit a loop, use the EXIT FOR statement.
There is a time limit for loops.
Example
The following code fragment uses a loop to insert a large number of dummy records into a
database table. If there is an error inserting a record, the loop is aborted to prevent creating more
errors.
FOR Counter = 1 TO 1000
ResultCode = SQLInsert(ConnectionID, "BatchDetails", "BindList1");
IF ResultCode <> 0 THEN
LogMessage("Error creating records! Aborting...");
EXIT FOR;
ENDIF;
NEXT;
Note: The time limit is checked only at the NEXT statement of the loop. Therefore, the first
iteration of the loop is always executed, even if it takes longer than the time limit.
Wonderware Training
Section 1 – Introduction to InTouch QuickScript 7-15
Examples of Loops
The following script uses a simple loop and an indirect tag to re initialize 100 tags (Tag001 to Tag100)
with a value of 0.
DIM Counter AS INTEGER;
FOR Counter = 1 TO 100
IndirectInteger.Name = "Tag" + Text(Counter, "000");
IndirectInteger.Value = 0;
NEXT;
The following script uses two nested loops and an indirect tag to reinitialize 1000 tags
(Line01_Tag001 to Line10_Tag100) with a value of 0.
DIM LineCounter AS INTEGER;
DIM TagCounter AS INTEGER;
FOR LineCounter = 1 TO 10
FOR TagCounter = 1 TO 100
IndirectInteger.Name = "Line" + Text(LineCounter, "00") + "_Tag" +
Text(TagCounter, "000");
IndirectInteger.Value = 0;
NEXT;
NEXT;
Wonderware Training
Lab 19 – Opening an Application with QuickScript 7-17
Introduction
In this lab, you will write a Key script that uses the F12 key on your keyboard to open the Microsoft
Calculator in Windows multiple times. Then, you will change the script so that if the calculator is
already opened, it calls the current instance when the F12 key is pressed, instead of opening a
new instance. Next, you will write a Data Change script to write the current mixer production totals
to an external file.
Objectives
Upon completion of this lab, you will be able to:
Write a Key script
Call a script function with parameters
Add conditional branching to a script using IF THEN ELSE ENDIF keywords
Wonderware Training
Lab 19 – Opening an Application with QuickScript 7-19
6. On the right side of the Key Scripts dialog box, click System.
Wonderware Training
Lab 19 – Opening an Application with QuickScript 7-21
8. In the body of the script, after StartApp, enter a space, followed by “calc”.
The line of script will look like the following image.
StartApp “calc”
9. On the right side of the Key Scripts dialog box, click Validate.
Wonderware Training
Lab 19 – Opening an Application with QuickScript 7-23
Test in Runtime
Next, you will test your Key script.
14. Click Runtime.
15. In WindowViewer, press F12 on your keyboard.
The calculator opens.
WindowViewer now becomes the active Windows application and the calculator is hidden
behind WindowViewer.
Wonderware Training
Lab 19 – Opening an Application with QuickScript 7-25
23. On the right side of the Key Scripts dialog box, click System.
The Choose Function dialog box appears.
24. Click InfoAppActive.
The InfoAppActive function is inserted in Line 1.
Wonderware Training
Lab 19 – Opening an Application with QuickScript 7-27
Note: This script checks if the calculator is already open. If it is opened it activates the
currently-opened instance by bringing the calculator into the foreground. Lines 3-5 of the script
start a new calculator only if one is not already opened.
Test in Runtime
Next, you will test your modified Key script.
44. Click Runtime.
45. In WindowViewer, press F12 on your keyboard.
The calculator opens.
46. Click the WindowViewer title bar.
WindowViewer now becomes the active application and the calculator is hidden behind
WindowViewer.
47. Press F12.
The activated calculator is displayed in the foreground in front of WindowViewer instead of
opening a new calculator instance. Only one instance can be seen on the task bar.
48. Close the calculator.
49. Click Development!.
Wonderware Training
Module 8 – Introduction to ArchestrA
Symbol QuickScript .NET
Section 1 – ArchestrA Symbol QuickScript.NET 8-3
Section 2 – ShowGraphic() and InTouch Windows 8-17
Lab 20 – Creating a Scalable Window Navigation Control 8-21
Section 3 – ShowGraphic and ArchestrA Symbols 8-31
Lab 21 – Building a Mixer Browser Using ShowGraphic 8-33
Lab 22 – Creating a Context Driven Alarm Window Using ShowGraphic 8-41
8-2 Module 8 – Introduction to ArchestrA Symbol QuickScript .NET
Module Objectives
Explain differences between ArchestrA QuickScript .NET and QuickScript
Explain how to use the ArchestrA Symbol Script Editor
Describe how to create Predefined scripts in an ArchestrA symbol
Describe how to create Named scripts in an ArchestrA symbol
Wonderware Training
Section 1 – ArchestrA Symbol QuickScript.NET 8-3
QuickScript.NET
QuickScript.NET is the name of the script language, and functionality used by ArchestrA symbols
in the InTouch environment. InTouch QuickScript.NET capabilities allow you to execute
commands and logical operations based on specified criteria being met. All ArchestrA Symbol
QuickScript.NET scripts are event driven, such as a data change, a condition, a mouse click, or a
timer. You can add conditional statements, loops, and local variables to the basic scripts to create
complex effects in your application.
QuickScript.NET types include the following:
Predefined On Show– Scripts that execute when the window on which the symbol is
embedded is opened
Predefined While Showing – Scripts that execute periodically while the window on which
the symbol is embedded remains open
Predefined On Hide – Scripts that execute when the window on which the symbol is
embedded is closed
Named Scripts:
Data Change – Scripts that execute each time a monitored expression changes
WhileTrue – Scripts that execute periodically while an expression remains true
WhileFalse – Scripts that execute periodically while an expression remains false
OnTrue – Scripts that execute when an expression transitions from false to true
OnFalse – Scripts that execute when an expression transitions from true to false
Action Scripts – An animation type which supports scripts that execute when a user
action is performed, such as clicking a mouse
QuickScript.NET includes library functions which act like pre-written scripts that can be called and
executed to perform additional complex functionality. These can be selected quickly by picking
them from a list to include in the script.
Because ArchestrA Symbol QuickScript.NET is event based, every script you build will require a
trigger to execute. For some scripts, the trigger is fixed by the script type you choose. For
example, the Predefined On Show script is driven by opening the window on which the symbol is
embedded. For this script type, you cannot modify the trigger behavior. On the other hand, if you
choose a Named Script, you must write an expression, either mathematical or logical, to trigger the
execution of the script. For example, the expression Pump == True, is a trigger that will execute
the script when the pump starts.
Some ArchestrA Symbol QuickScript.NET scripts execute periodically. These scripts always
include the word While in the name of the script type. These scripts provide a time field specified in
milliseconds for the frequency at which the script will execute. For example, a Named Script
WhileFalse, has its period field set to 1000 ms. This means as long as the expression evaluates to
False, once per second, or 1000 ms, the script will repeated execute indefinitely. As soon as the
script expression evaluates to True, script execution stops.
For all While scripts (repeating at a specified period), the script will not execute the first time until
the period has elapsed. Additionally, InTouch is not based on a scan engine with guaranteed
interval, so the only guarantee is that the script will NOT execute faster than the period specified.
Finally, WindowViewer will make every attempt possible to run scripts as fast as the specified time,
however, the Windows operating system is not deterministic, like a PLC so WindowViewer is
subject to the operating system behavior.
Global Scope
Because ArchestrA Symbol QuickScript.NET only exists inside graphic symbols, and graphic
symbols are associated with a window being opened in memory, therefore, these scripts cannot
executed in WindowViewer at a system-wide level. For example, you build a security logon symbol
which manages authentication and access to your InTouch application and place this symbol on a
menu window. If the menu window is accidentally closed, your entire application becomes
unsecured and unauthorized individuals can access any part of your application. It is therefore, not
recommended to perform global scope scripting using ArchestrA Symbol QuickScript.NET.
Local Scope
ArchestrA Symbol QuickScript.NET only exists inside graphic symbols. Therefore, these scripts
are local scope execution only. Without the window on which the graphic is embedded opened, the
triggers which drive the execution of these scripts do not exist. A work-aound to this behavior is to
place a window in a location where it cannot be closed by operator interaction or a replace type
window that may touch it. By opening this window when WindowViewer starts, this ensures that
the scripts on that window continue to run for the life of the application. However, if anything should
close that window, all ArchestrA Symbol QuickScript.NET scripts embedded on that window will
stop.
Predefined Scripts
Predefined Scripts are built into ArchestrA symbols The three types On Show, While Showing and
On Hide closely match the three window script types of InTouch. This is because the symbol is
embedded on the window and its own open (Show), running (Showing) and closed (Hide) status is
tied to the window on which it is embedded.
The three types of Predefined scripts are:
On Show – The symbol is shown when the window is opened. This script type is typically
used to perform any setup such as initializing custom properties or tags which are
required for the execution of ArchestrA Symbol QuickScript.NET. However, any script
which needs to be executed the moment the symbol appears is appropriate for this script
type.
While Showing – As long as the window remains open in memory, the symbol is showing.
This script is typically used to monitor or modify state changes to uppdate counters,
change flags, and perform other periodic functions. While Showing scripts require a
period, or frequency, at which the script will repeatedly execute. The While Showing script
will repeatedly execute no sooner than the specified period, however, the script will
execute as long as the window on which the symbol is embedded remains open.
On Hide – When the window closes, all of the symbols embedded on the window are
unloaded from memory. Prior to this, all On Hide scripts will execute. Any states of custom
properties or tags can be stored or modified at this point to reflect the final condition of the
symbol when it is closed.
Wonderware Training
Section 1 – ArchestrA Symbol QuickScript.NET 8-5
Named Scripts
Named Scripts are user created scripts with a predefined list of triggers. Each Named Script
requires an expression. Expressions can be as simple as a custom property or tag that is being
monitored for state change or as complicated as a mathematical formula or logical evaluation. The
trigger types for the Named Scripts are as follows:
Data Change – Scripts that execute each time a monitored expression changes. For
example, a Data Change Script could monitor each time a lot number is increased. Data
Change scripts are ideal for relatively slower changing process values. Performance could
be impacted if a Data Change script were tied to a temperature sensor or other rapidly
changing data value.
WhileTrue – Scripts that execute periodically while an expression remains true. For
example, the expression Temperature > 120 could be used to monitor when the
temperature exceeds 120 degrees.
WhileFalse – Scripts that execute periodically while an expression remains false. For
example, Connection == True could be monitored to provide an alert to an operator when
a connection is lost.
OnTrue – Scripts that execute when an expression transitions from false to true. For
example, CookieBatchStart == True could monitor the start of a cookie batch process.
OnFalse – Scripts that execute when an expression transitions from true to false. For
example, an expression of Flag == True could be used to monitor any time the flag is
reset.
Action Scripts
Action Scripts are an animation type which supports scripts that execute when a user action is
performed, such as clicking a mouse. Action scripts have 15 trigger types. These can be
summarized as four behaviors with each mouse button: click, double-click, hold, release. The last
three are cursor hover functionality. When the cursor is floating over the graphic element, On
Mouse Over, when the cursor stops floating over the graphic element, On Mouse Leave, and while
the cursor is floating over the graphic element, While Mouse Over. These last three Action Script
triggers include an after period field. This field allows you to control how long to wait before
executing the script. This allows normal mouse operation without accidentally firing Action scripts.
If the delay is sufficient, the operators actions must be deliberate in order to execute the script.
Area Description
1 Script List
2 Expression Field
Provides the available execution conditions for the type of script you are writing.
3 Trigger Type
Drop-down list to select the method of execution.
4 Period
Frequency at which the script will execute. Applies only to While type scripts.
5 Toolbar
Select lists for functions, graphics, objects, and attributes, tags and custom properties.
6 Error Message Display
Line number and column where the error occurred in the body of the script.
7 Body of Script
Line numbered script entry field. Includes color coded key words and operators with auto-
complete functionality.
8 Script Erase and Validate Buttons
Wonderware Training
Section 1 – ArchestrA Symbol QuickScript.NET 8-7
Element Color
Keywords Blue
Syntax highlighted while typing.
Comments (both single line and multi-line) Green
Syntax highlighted while typing.
Strings Purple
Syntax highlighted while typing.
Function names, numeric constants, Black
operators, semicolons, dim variables, alias
See descriptions for Attribute names and Reserved words.
variables, and so on
Attributes, InTouch Tags, Reference Strings Maroon, bold face
Reserved words Red, non-bold face
.NET type names Teal, non-bold face
Autocomplete Features
The script editor autocomplete incorporates several features for use while authoring ArchestrA
Symbol QuickScript.NET scripts. Autocomplete displays a context-sensitive list of options for script
elements, keywords, object and attribute names, and programmatic constructs. You can identify
the context from the icons displayed at the bottom of the autocomplete pop-up window.
Autocomplete has the following features:
Provides an autocomplete tag reference in a selectable list box.
Provides method parameter help in an autocomplete list box including context-specific
suggestions covering definitions, keywords, script elements, and programmatic
constructs.
Automatic word completion of custom properties, element properties, tags, dotfields,
methods, programmatic constructs, and other script elements.
Press Ctrl+Space to display all available autocomplete options and variables for the selected
location in the script. Autocomplete represents each scripting element with a different icon. Icons
represent keywords, operators, Variables, tags, and windows.
Wonderware Training
Section 1 – ArchestrA Symbol QuickScript.NET 8-9
Script Functions
A script function is a script which has been written and made available from the function list for
calling from other scripts. A script function may include arguments or parameters which must be
specified when the function is called. For example, the following shows a syntax for a function with
two parameters:
StringLeft( Text, Chars );
This example will select the number of characters specified in the Chars parameter from the left
side of the text parameter. If Text contained Mixer100_Temperature_PV, and Chars contained 8,
the StringLeft function would return Mixer100.
Some functions return a result. When a function returns a result this must be captured in either a
tag or a local variable if required. Without assigning the return result, the script function will fail to
validate and the script will not save. Some functions which return a result can also be used in an
animation expression directly.
Function Help
To access help documentation for a script function, in the function selector, click the Help button.
Help documentation for each function includes proper syntax usage, details on each parameter,
and examples of how to use the script function in the script.
Script Syntax
The syntax in scripts is similar to the algebraic syntax of a calculator. Most statements are
presented using the following form:
a = (b - c) / (2 + x) * xyz;
This statement places the value of the expression to the right of the equal sign (=) in the variable
location named “a.”
A single entity must appear to the left of the assignment operator =
The operands in an expression can be constants or variables
Statements must end with a semicolon (;)
Entities can be concatenated by using the plus (+) operator. For example, if a data change script
such as the one below is created, each time the value of “Number” changes, the indirect entity
“Setpoint” changes accordingly:
Number=1;
Setpoint = "Setpoint" + Text(Number, "#");
Where the result is “Setpoint1.”
Documenting Scripts
Both single line and multi-line comments are supported. Single line comments start at an '
(apostrophe) in a source code line that has no matching ending ' in the line. Multi-line comments
start with a { (opening curly brace) and end with a } (closing curly brace) and can span multiple
lines as the name suggests.
Examples:
Dim A; 'This is a single line comment
Dim B; {This is an example
of a multi-line comment}
Wonderware Training
Section 1 – ArchestrA Symbol QuickScript.NET 8-11
In the above script, a custom property named UnauthorizedAccess is evaluated and compared
to a numeric value of 1, and if it is found to be TRUE, the script will proceed to the statement
SecurityAlert = True; which will set the custom poperty named SecurityAlert to True.
If the custom property UnauthorizedAccess contained any value other than 1, even a value such
as 1.0001 (which is not equal to 1), then the system skips over the statement and ends after the
ENDIF; portion of the script. IF THEN ENDIF; is the most basic form of decision making in a script.
The following comparison operators are also valid for conditional expressions:
Note: FOR-NEXT loops can be nested. The number of levels of nesting possible depends on
memory and resource availability.
Wonderware Training
Section 1 – ArchestrA Symbol QuickScript.NET 8-13
WHILE Loop
WHILE loop performs a function or set of functions within a script several times during a single
execution of a script while a condition is true. The general format of the WHILE loop is as follows:
WHILE <Boolean_expression>
[statements]
[EXIT WHILE;]
[statements]
ENDWHILE;
Where: Boolean_expression is an expression that can be evaluated as a Boolean as defined in the
description of IF…THEN statements.
It is possible to exit the loop from the body of the loop through the EXIT WHILE statement.
The WHILE loop is executed as follows:
1. The script evaluates whether the Boolean_expression is true or not. If not, program execution
exits the loop and continues after the ENDWHILE statement.
2. The statements in the body of the loop are executed. The loop can be exited through the EXIT
WHILE statement.
3. Steps 1 through 2 are repeated.
Note: WHILE loops can be nested. The number of levels of nesting possible depends on memory
and resource availability.
ShowGraphic() Function
Associating all Galaxy graphics with an InTouchViewApp template enables deployed and
published InTouch applications to run show graphic requests made of any graphic in the Galaxy
without having to embed them in the application.
The ShowGraphic() function uses the graphic as a parameter. Associating all Galaxy graphics
ensures that:
The graphic is deployed and available at runtime, whether or not it is referenced by an
InTouchViewApp
Template symbols referenced by the ShowGraphic() function are deployed and available
at runtime
Note: The term graphic includes any symbol or client control present in the Graphic Toolbox,
and any symbols owned or inherited by templates and instances.
Important: The ShowGraphic script function can be used in the action script of a symbol, named
script, and predefined script. Although the system allows the inclusion of it in a server script, such
as Start Up, On Scan, Off Scan, Shut Down, and Execute, the function cannot be ran at runtime.
Wonderware Training
Section 1 – ArchestrA Symbol QuickScript.NET 8-15
The HideGraphic script function can be called from any ArchestrA graphic that is being used in the
InTouch application.
ShowGraphic() Syntax
Use the ShowGraphic() to display a graphic within a popup window.
Dim graphicInfo as aaGraphic.GraphicInfo;
graphicInfo.Identity = "<Identity>";
graphicInfo.GraphicName = "<SymbolName>";
ShowGraphic( graphicInfo );
HideGraphic() Syntax
Use the HideGraphic() script function to close any displayed graphic given its Identity.
HideGraphic(string identity);
The ShowGraphic() and HideGraphic() script functions are available in managed or published
InTouch applications only.
Closing a Symbol
You can close a symbol, displayed using the ShowGraphic script function, by running the
HideGraphic or HideSelf script functions, clicking the Close Window button of the graphic popup
window, if configured, or by closing WindowViewer. You cannot close the graphic by closing the
InTouch window or the symbol that opened the graphic.
Windows opened by the ShowGraphic script function or ShowSymbol animation are loaded
dynamically and are not exposed at runtime. You cannot close these windows using the
WindowViewer Close Window dialog box.
Wonderware Training
Section 2 – ShowGraphic() and InTouch Windows 8-17
Overview
Earlier in this course, you used a simple mechanism for navigating through the windows of an
InTouch application using pushbuttons with Show Window animations. This simple concept of
clicking a button to go to a window is easy to understand when learning InTouch for the first time,
and it works for an application that only has a few windows.
However, designs based on one pushbutton for each window in the application will likely run into
scalability issues as the application grows. This method may be entirely impractical for medium- to
large-sized applications without extensive management of menu windows and maintenance of
those windows. If an application had 200 windows, would you design a single large menu window
with 200 tiny buttons with labels to navigate around your application? Maybe you would create a
window with a few buttons that call up additional menu windows with more buttons. What if you
need to add new windows in the middle of your existing menu design? Would the design require
repositioning and resizing dozens of buttons to add one or more new buttons? What if the InTouch
application starts out small at the beginning of the project, but will grow to 1,000 windows after
many years when the project is completed? How will you maintain your navigation design? How
many windows will your menu system require and how much screen real estate will be consumed
by the layout of all these navigation buttons? Will operators be able to find things easily and
navigate quickly?
Now, you will address issues of navigation scalability and maintenance. This will be done using a
method that allows for the easy organization of window names using the Combo Box windows
controls. Window lists can be auto sorted, avoid duplicates, and allow the easy insertion of new
window names into the list. Navigation designs using window controls can scale from a few
windows all the way up to thousands, while using a minimum of screen real estate and keeping all
navigation in a single place.
ShowGraphic( ) Scripting
Show Symbol animation has limitations, such as only allowing one Popup window, and requiring
fixed references to InTouch tagnames, which makes working with custom properties more
complicated. The ShowGraphic script function improves all of these items.
The ShowGraphic script function imitates most of the features of the Show Symbol animation. For
each Show Symbol animation feature in the Edit Animations window, there is an equivalent line of
script in the ShowGraphic script function. For example, in the Show Symbol animation, there is a
check box named Has title bar. In ShowGraphic, there is a line of script named
GraphicInfo.HasTitleBar = true;.
Using the ShowGraphic script function, you can design a layered application where additional
detail can be discovered by drilling down into a process. Each click brings up a window with more
detail; as you close the detailed windows, you are returned to the top level displays again. Or, you
can bring up multiple graphics arranged in rows and columns to show comparative process details
side-by-side. You can create building blocks that can be reused in many combinations of
arrangements and displays. The power of the ShowGraphic function is astounding with just a little
imagination.
The minimum ShowGraphic script must contain the following four lines:
Dim graphicInfo as aaGraphic.GraphicInfo;
graphicInfo.Identity = "<Identity>";
graphicInfo.GraphicName = "<SymbolName>";
ShowGraphic( graphicInfo );
The ShowGraphic function is really made up of two parts. The key execution part is the last line of
the script, which actually performs the task of making the popup window appear, (ShowGraphic
( graphicInfo); this must always be the very last line of the ShowGraphic function. The second part
is all of the other lines of script that define the popup window.
GraphicInfo is a structure that holds the definitions, configuration options, and properties that
describe the popup window. This includes: (1) identifying the popup window, (2) specifying what
graphic to show in the popup window, (3) if the popup window will be user interactive, (4) where on
the screen the popup window will appear, (5) the size of the popup window, (6) what value to set
for each custom property in the graphic, and (7) what additional features the popup window will
have. For example, will it have a title bar and if yes what will be the caption, will it have a close
button or not, and will it be resizable?
The ShowGraphic function can be called from any symbol script, including a predefined script (On
Show, While Showing, On Hide), a Named Script, or an Action Script. Within the Script Function
Browser, called from within any Symbol script editor, highlight the ShowGraphic function, and click
Help to open detailed help on the ShowGraphic function. The Help file includes detailed
enumeration tables of all the positions, sizes, and properties that can be used within the function.
The Help file also includes examples that can be copied and pasted into the script as-is.
Wonderware Training
Section 2 – ShowGraphic() and InTouch Windows 8-19
One of the most powerful aspects of the ShowGraphic function is the CustomProperty-Value pair
array. The last portion of the script before calling the graphic, this array defines each Value,
Reference, or Expression that will be assigned to each custom property in the symbol (graphic)
being shown. This allows any symbol from the library to be shown in runtime with all of its custom
properties assigned at runtime, such as linked to InTouch tagnames.
completes the string with the string literal is the level value.This example combines three different
building blocks using string concatenation with the addition operator to form a final sentence.
Wonderware Training
Lab 20 – Creating a Scalable Window Navigation Control 8-21
Introduction
In this lab, you will create the Nav symbol, which uses a window control to allow the operator to
navigate between different windows in the application. This scalable method of navigation uses
the smallest amount of screen space.
Objectives
Upon completion of the this lab, you will be able to:
Build a combo box containing window names
Use the ShowGraphic function to open native InTouch windows
5. Click OK.
Wonderware Training
Lab 20 – Creating a Scalable Window Navigation Control 8-23
Wonderware Training
Lab 20 – Creating a Scalable Window Navigation Control 8-25
Wonderware Training
Lab 20 – Creating a Scalable Window Navigation Control 8-27
22. In the Script Function Browser dialog box, expand Graphic Client, and select
ShowGraphic.
27. In Line 2, place the cursor between the quote and semicolon, and enter + WindowName.
Wonderware Training
Lab 20 – Creating a Scalable Window Navigation Control 8-29
Wonderware Training
Section 3 – ShowGraphic and ArchestrA Symbols 8-31
This section will explain how to use advanced features of the ShowGraphic script function.
Overview
This section explains how to use advanced features of the ShowGraphic script function to popup a
window in runtime. Advanced ShowGraphic functionality includes popup window size, position,
behavior, and assigning custom property value pairs. At runtime the ShowGraphic script function
can be used to call a graphic from the library into a popup window that can be positioned and sized
as desired.
Configuration options include the ability to set the modal/modeless property. Which means the
popup window can be configured as a modal window to prevent interaction with WindowViewer
until the popup window is closed. Additional properties allow you to enable or disable the title bar,
to change the caption of the title bar, to allow the popup window to be resized, or to change the
scale of the graphic.
A powerful feature of the ShowGraphic advanced functionality is the ability to assign InTouch tags
to the custom properties of the called graphic. This enables ShowGraphic to be used as a data
browser. A reusable symbol can be called and the data points in the graphic changed dynamically
to point to different data sources from the field. For example, the Mixer graphic used in this course
can be called by ShowGraphic with custom property value pairs assigned to Mixer300 data. This
technique acts like a mixer browser, allowing the same graphic to be called over and over again
depending upon which mixer you want to view.
Closing a Symbol
You can close a symbol, displayed using the ShowGraphic script function, by executing the
HideGraphic() or HideSelf() script functions, clicking the Close Window button of the graphic
popup window if configured, or closing WindowViewer. You cannot close the graphic by closing
the InTouch window or the symbol that launched the graphic. Windows opened by the
ShowGraphic() script function are loaded dynamically at runtime. You cannot close these windows
using the WindowViewer close window dialog box.
Wonderware Training
Lab 21 – Building a Mixer Browser Using ShowGraphic 8-33
Introduction
In this lab, you will build a mixer browser using the Mixer symbol. The Mixer symbol will be called
in a Frame window. You will add navigation for the operator to select a mixer and use the
ShowGraphic function to update the custom properties of the Mixer symbol to link the mixer’s
InTouch tags.
Objectives
Upon completion of this lab, you will be able to:
Use ShowGraphic to create a mixer navigation view with a Frame window
4. Click OK.
The new window is created and opened.
Wonderware Training
Lab 21 – Building a Mixer Browser Using ShowGraphic 8-35
Wonderware Training
Lab 21 – Building a Mixer Browser Using ShowGraphic 8-37
16. In the Static Values and Captions area, ensure there are only four rows available, and edit
the Value column as follows:
Mixer100
Mixer200
Mixer300
Mixer400
Note: You may also use Ctrl + mouse wheel to change the text size in this window.
Next, you will modify the script based on the historical data source option you selected earlier in
the course.
24. Delete any existing text from the body of the script.
25. Select the text file and copy its contents into the body of the script according to the table
below.
Note: Your instructor will assist you to select the proper file.
Wonderware Training
Lab 21 – Building a Mixer Browser Using ShowGraphic 8-39
The picture below displays the contents of the Lab 21 - Option 1 and 2 file.
Wonderware Training
Lab 22 – Creating a Context Driven Alarm Window Using ShowGraphic 8-41
Introduction
In this lab, you will add a button to the Mixer symbol to create a popup alarm window that filters an
Alarm Client to show only alarms for the current mixer.
Objectives
Upon completion of this lab, you will be able to:
Use ShowGraphic to create a popup Window
Create a Popup context Alarm View
Use HideSelf functionality
Create an Action Script with On Left Click/Key/Touch Down Trigger
Name: Query
Data Type: String
7. Click OK.
Wonderware Training
Lab 22 – Creating a Context Driven Alarm Window Using ShowGraphic 8-43
8. Add a button at the bottom of the Alarm Client, and configure the properties as follows:
Name: OkButton
Element Style: Intensity1
Text: OK
Name: AlarmsButton
Element Style: Intensity1
Text: Alarms
Wonderware Training
Lab 22 – Creating a Context Driven Alarm Window Using ShowGraphic 8-45
15. In the Element list, double-click AlarmsButton, and add an Action Scripts animation.
16. In the script body, enter the following:
Note: You may copy and paste the script from the C:\Training\Lab 22 - Creating a Context
Sensitive Alarm Popup View file.
Wonderware Training
Module 9 – Security
Section 1 – OS Security Implementation 9-3
Lab 23 – Setting Up and Using OS Security 9-13
Section 2 – Lock Down Your Application 9-29
Lab 24 – Locking Down Your Application 9-35
9-2 Module 9 – Security
Module Objectives
Define the InTouch Security Options
InTouch Security
OS Security
ArchestrA Security
Wonderware Training
Section 1 – OS Security Implementation 9-3
Overview
InTouch security is a two-step process of first determining if the person attempting to use an
application is recognized as a valid user. The second step determines what InTouch privileges are
granted to an authenticated user.
InTouch security includes options for a variety of applications. Securing an InTouch application
requires both configuration and application design changes. Application designers may want to
secure the operating system, audit operators' actions, or secure the InTouch application itself. In
embedded or restricted environments, the top concern may be to limit the operator's access to other
Windows applications or the operating system. There are script functions available to restrict
access to certain keys on the Windows keyboard. There are ways to configure WindowViewer™
(View) to always run maximized and to hide its menu so that operators cannot close or minimize it.
In other instances, the primary goal of operator login is to audit the operator's actions and track these
actions. The InTouch Alarm and Event system may be configured to record operator actions along with a
time stamp and the name of the operator who performed the action or acknowledged the alarm, or failed to
take action or acknowledge the alarm.
In some other cases, security means restricting features or restricting access to areas of the
application based on user names or roles. This is done by setting a visibility or disable link on the
graphic, such as only allowing a button to be clicked if the operator is part of the supervisor’s group
with the proper training.
The operating system security type passes authentication requests to the Windows operating system
or to the domain security through Active Directory. The OS Security option allows InTouch to meet
security requirements in regulated industries. These specifications are established by the Food
and Drug Administration (FDA) in 21 CFR Part 11.
OS Security adds the benefits of password expiration, restricting the number of unsuccessful login
attempts, policing to restrict the strength of passwords, and the use of special characters,
encryption, and other benefits.
Using OS Security
An OS security (operating system-based) authentication method inherits enforcement of
some account policies from the Windows operating system, while other policies are
enforced from the InTouch HMI. Password policies such as maximum and minimum
password age and minimum password length are enforced by the operating system.
User names used during installation act as a part of the operating system. The Windows
domain must be set up with the desired account policies to enforce these standards. The
InTouch HMI enforces the inactivity time-out period.
In the operating system-based authentication method, user names can be chosen from
the list of users associated with a Windows Network Domain or Workgroup. Each user
name has an assigned access level that determines the user's authorization for a given
activity. Because the operating system manages passwords internally, the InTouch HMI
does not store passwords on the node hosting the application.
Operating system-based security uses the InTouch AddPermission() script function to
define and maintain a list of users and their corresponding access levels. This list, created
after the execution of the AddPermission() call, is written to disk. The file containing the
authentication details of users is not copied to NAD client nodes.
The operator can log on to the application by executing the
Wonderware Training
Section 1 – OS Security Implementation 9-5
Log on menu command under Security in the WindowViewer Special menu (if the
Special menu is shown), or you can create a custom log on window with touch-sensitive
input objects that are linked to internal security tags.
The commands used to establish security on an application are located under
Security on the Special menu in both WindowMaker and WindowViewer. The security
commands are used to log on and off the application, change passwords, and to configure
the list of valid user names, passwords, and access levels.
For example, you can control access to a window, the visibility of an object, and so on, by
specifying the logged on operator's access level must be greater than 2000.
Auditing
Tracking operator log in and log out, and tracking operator’s actions, requires enabling both
security and the InTouch Alarms and Events subsystem. When users are created to be used in
an InTouch application, audit trails can tie operators to all alarms/events that occur during the time
that they are logged in to the system. Using the .NET Alarm Client along with the Alarm DB
Logger, it is possible to search through historical events and alarms to determine who the
operator was at the time the event occurred.
Note: InTouch logs activities of the user who is logged in. Proper training is necessary to make
sure operators log in and out of the system during shift turnover to ensure the person performing the
activities is the person logged in.
No Authentication
The default security setting for InTouch applications is "None." When no authentication is used,
$Operator and $OperatorName are both set to None and $AccessLevel is 9999. The Special/
Security options in the menu bar in View are all disabled. Also, the binary file password.bin is not
created in the application directory.
Wonderware Training
Section 1 – OS Security Implementation 9-7
OS Authentication
With OS authentication, users and groups configured in the local machine (when leaving the
domain field blank or specifying the node name of the local machine), or when using Domain
Security such as through Microsoft Active Directory, are assigned access levels using the
AddPermission() script function. There is a tight coupling of the Microsoft group name with a
specific $AccessLevel through this script function. Beyond this relationship, there is no means for
InTouch to know how your IT department or HR Department are using those groups. For example,
your HR Department may have an employment category in Active Directory named Guests and
Visitors, which an InTouch designer may choose to grant an $AccessLevel of 9000, giving them
administrator rights within InTouch. Beyond this association through scripting, InTouch has no
ability to check the meaning or usage of the Microsoft group. Therefore, InTouch designers must
work closely with IT and HR to establish the proper associations based on certifications,
experience, and training within these groups.
OS Users may be part of one or more groups; if multiple access levels are set to multiple groups, a
user logging in to the InTouch application will get the highest access level assigned by any of the
groups he/she is part of.
Note: Once the OS Security Type has been selected, the user registered during the InTouch
installation is the only user who has permission to change the Security Type.
Three internal security tags are used in buttons in animation link expressions or QuickScripts, and
so on. They are $Operator, $AccessLevel, and $OperatorName. These tags control whether or
not the logged-on user is allowed to perform specific functions.
For example, to make an object become visible based on the logged on users’ access level, the
following statement could be used in a Visibility animation link expression:
$AccessLevel >= 2000
Or, a QuickScript can be bounded by an IF statement:
IF $Operator == "DayShift" THEN
Show "Control Panel Window";
{and other lines that only execute for the DayShift Operator}
ENDIF;
You can also control an object's touch functionality based on the value of an internal security
tagname by using the Disable animation link.
For example:
In this example, when no one is logged on, the object or button is secured from tampering.
Wonderware Training
Section 1 – OS Security Implementation 9-9
AttemptInvisibleLogon()
Attempts to log in to InTouch using the supplied credentials.
Syntax
DiscreteTag=AttemptInvisibleLogon
( "UserId","Password", "Domain" );
Remarks
An attempt is made to log in to InTouch using the supplied credentials. The domain is ignored if
the security mode is not OS. If the log in attempt succeeds, TRUE is returned and the system
tags $OperatorDomain, $OperatorName, $AccessLevel, and $Operator are updated
accordingly. If the log in attempt fails, FALSE is returned and the currently logged in user (if
any) continues to be the current user.
Logoff()
Logs the user out of InTouch.
Syntax
DiscreteTag=LogonOff();
Remarks
Logs the user off.
Wonderware Training
Section 1 – OS Security Implementation 9-11
GetAccountStatus()
Used to determine when a user’s password will expire.
Syntax
GetAccountStatus( Domain, UserID );
Remarks
This is used to determine when a user’s password will expire. Return value will display the
number of days (positive value) until the user’s password expires. GetAccountStatus also
displays the following account status values:
Account password expired = -1
Account password will never expire = -2
Account locked out = -3
Account disabled = -4
Account info failed = -5
Users can write a script to display a window with either the number of days until the user’s
passcode expires or the proper message/warning that corresponds to the return value of the
function.
LogonCurrentUser()
Whoever is logged in to the computer will be logged in to InTouch.
Syntax
LogonCurrentUser();
Remarks
This script function is designed for InTouch to run in OS security mode. When the script
function is called, whoever is logged in to the computer will be logged in to InTouch.
QueryGroupMembership() Syntax
DiscreteTag=QueryGroupMembership("Domain","Group");
Remarks
This is valid for OS security mode only and applies to the currently logged in user. If a user is
currently logged in and is part of the group that is located on the domain, a TRUE is returned;
in all other cases, a FALSE is returned.
Wonderware Training
Lab 23 – Setting Up and Using OS Security 9-13
Introduction
In this lab, you will set up Operating System (OS) Security in InTouch. OS Security allows InTouch
to use Active Directory or Local Machine security to authenticate users. You will set up the user
interface for operators to log in to the application, assign InTouch access levels based on group
membership, and verify group membership.
Objectives
Upon completion of this lab, you will be able to:
Configure a security environment with OS Security
(without Active Directory, must use local users and groups)
Use an Application script to set up user permissions and access levels
Use Condition scripts to support a native InTouch script function called from ArchestrA
Graphics
Log in using the PostLogonDialog( ) script function
Log off the current user with the LogOff( ) script function
Set Up OS Security
For classrooms without a domain set up, local users and groups must be created before starting
this lab. If your instructor directs you to “Create Local Users and Groups (Non-domain
Classroom Setting Only)” on page 9-26, follow the steps there first, and then come back here to
follow the steps below. If your instructor does not direct you to Create Local Users and Groups
later in the lab, follow the steps below.
In the following steps, you will enable OS Security and create security scripts.
1. Close WindowViewer.
2. On the WindowMaker Special menu, select Security | Select Security Type | OS.
Wonderware Training
Lab 23 – Setting Up and Using OS Security 9-15
Note: You may copy and paste the script from the C:\Training\Lab 23 - Setting Up and
Using OS Security.txt file.
Note: Your instructor will provide the domain name for this script.
The Application On Startup script executes when WindowViewer starts. Any modifications
made to this script after WindowViewer is launched will require WindowViewer to be restarted.
6. Click OK.
7. In the Tagname Dictionary, create a tag named GroupMembership.
8. Change the Type to Memory Message.
9. In the Initial Value field, enter None.
Wonderware Training
Lab 23 – Setting Up and Using OS Security 9-17
Note: You may copy and paste the script from the C:\Training\Lab 23 - Setting Up and
Using OS Security.txt file.
GroupMembership = "";
IF QueryGroupMembership( "CLOUD", "Plant Operators 1" ) == 1 THEN
GroupMembership = "Operator";
ENDIF;
IF QueryGroupMembership( "CLOUD", "Plant Supervisors 1" ) == 1 THEN
GroupMembership = "Super";
ENDIF;
IF QueryGroupMembership( "CLOUD", "Application Administrators" ) == 1 THEN
GroupMembership = "Admin";
ENDIF;
IF $Operator == "None" THEN
GroupMembership = "None";
ENDIF;
Wonderware Training
Lab 23 – Setting Up and Using OS Security 9-19
Name: DisplayAccessLevel
Type: Output
EngUnits: False
QualityStatusIndicator: False
Outline: False
Old New
##.## #
Label Access Level
Name: DisplayOperator
Type: Output
QualityStatusIndicator: False
Outline: False
Old New
##.## #
Label Operator
Wonderware Training
Lab 23 – Setting Up and Using OS Security 9-21
24. On the canvas, duplicate DisplayOperator, and place the duplicate below the original.
25. Name the duplicate DisplayGroup.
26. Substitute strings, and replace Operator with Group.
27. Substitute references, and replace InTouch:$Operator with InTouch:GroupMembership.
28. Right-click the canvas and select Select All.
29. On the Alignment toolbar, click Align Left.
31. Reposition the elements to make room on the left for buttons that will be added in the following
steps.
Name: ButtonLogOn
Element Style: Intensity1
Wonderware Training
Lab 23 – Setting Up and Using OS Security 9-23
The initial view in WindowMaker does not show the Application Style Library appearance. This
will be updated when tested in runtime.
Test in Runtime
Finally, you will test logging in and logging off at runtime.
53. Click Runtime.
The SecurityLogon symbol is displayed in the Menu window.
Wonderware Training
Lab 23 – Setting Up and Using OS Security 9-25
Note: Your instructor will provide passwords that adhere to the local security policy.
User name Full name Password User must change password at next logon
maryl Mary Lee unchecked
karent Karen Turner unchecked
johnj John Johnson unchecked
5. Click Close.
Next, you will create new local groups and assign users.
6. In Computer Management, right-click Groups, and select New Group.
Wonderware Training
Lab 23 – Setting Up and Using OS Security 9-27
7. Configure each of the groups, and add the user associated with that group as follows:
8. Click Close.
9. Close Computer Management.
10. Return to “Set Up OS Security” on page 9-14 and continue this lab.
Wonderware Training
Section 2 – Lock Down Your Application 9-29
Overview
Enhancing Security may begin with basic configuration options available on Special | Configure
options, including the ability to disable the menu bar or individual menu items, the Tag Viewer, or
even make WindowViewer impossible to close.
WindowViewer can be configured to automatically logout users based on inactivity. The Inactivity
timeout option is accessible on Special | Configure | WindowViewer. Additionally, Home
windows may be defined on Special | Configure | Home Windows so that the initial window or
windows, which appear when WindowViewer is first started do not give access to any sensitive
areas.
But the most significant power in customizing and enhancing security is done through InTouch
scripts to build sophisticated and robust applications. You may use InTouch scripts to create a
completely regulation compliant and secure application.
In terms of security, scripts can generally be run in two different ways:
Event-based scripts run once when an event occurs allowing you to take immediate,
unassisted action. For example, an event-based script can run after a condition is met or
the value of a key process I/O point changes. Using I/O tagnames tied to external security
systems, such as door locks and proximity alarms, or other external security stimuli,
InTouch scripts can be used then to handle a wide array of standard operating
procedures, work flow, or processes insuring your people, facility, products, services, and
investments remain secure
Time-based scripts run periodically to continue to keep systems running within
operational norms or where predictive measures can be taken to avert failure or downtime
InTouch provides a number of System tags and script functions that allow you to configure security
for the individual application. By combining scripts with system tags related to security, you can
add a number of powerful features to your application, monitoring special conditions, and dealing
with critical events for example environmental or safety issues. You can also use Touch scripts for
sophisticated operator input into the system, and apply levels of security to various functions.
Note: You can use $InactivityWarning in a Condition QuickScript to show a window warning to
operators that they are about to be logged off the system. If the operators click the mouse, press a
key, or perform an action using any other pointing device before the specified timeout elapses, they
are not logged off. $InactivityWarning and the timer are reset.
In the Timeout field, type the number of seconds that can elapse with no operator activity (mouse
clicks or keystrokes) before the system discrete tagname $InactivityTimeout is set to 1 (True).
When $InactivityTimeout is true, the system sets the logged on operator name to the reserved
name None and sets the security tagname, $AccessLevel, to 0.
Note: You can use $InactivityTimeout in a Condition QuickScript to show a window telling the
operators that they have been logged off the application.
You can use the Timeout feature independently of the Warning feature. However, the Timeout
value must be greater than the Warning value for proper use of both system tagnames. After a
successful log in, the timers for both the warning and timeout start. For example, set
$InactivityWarning to 30 and $InactivityTimeout to 45. The operator will be logged off 15
seconds after the $InactivityWarning variable is set to 1.
Wonderware Training
Section 2 – Lock Down Your Application 9-31
Use Title Bar options to hide the application's title bar in runtime.
Use Miscellaneous options to disable certain keystrokes such as Ctrl, Alt, Esc, and Win. You can
also set WindowViewer window as maximized at all times.
For more information please see the System Platform documentation.
InTouch Authentication
InTouch authentication uses a binary password file that contains user identification, passwords,
and access levels. In addition, you can use Operating System authentication, ArchestrA
authentication, or no authentication at all.
In WindowMaker, access security commands are available from the Special menu, Security
options. These commands are used to log on and off the application, change passwords and to
configure the list of valid user names, passwords, and access levels.
You can link a User Input - Discrete button to the $ConfigureUsers tag to allow an authorized
user with an access level of equal to or greater than 9000 to display the Configure Users dialog
box. The dialog box is used to edit the security user name list.
When the user clicks the button, the value of the $ConfigureUsers tagname is set to 1 and the
Configure Users dialog box appears. When the user closes the dialog box, the system resets the
value to 0 (This is a system discrete tag intended for write-operation only).
If the Special menu does not display in WindowViewer, you can create a custom logon window to
allow users to log on to the application.
You can also link a User Input - Discrete button to the $ChangePassword tagname to show the
Change Password dialog box and allow the user to change his/her password. When the user
clicks the button, the value of the $ChangePassword tagname is set to 1 and the Change
Password dialog box appears.
When the user closes the dialog box, the system resets the value to 0 (This is a system discrete
tagname intended for write operation only.)
The None and Administrator names are reserved. Only the password of the Administrator may
be changed. Once you have configured user names for your application, you should change the
Administrator name's password since it will more than likely become known to most users of the
system. The Administrator default access level (9999) is the highest and allows access to
everything including the Configure Users menu command.
Log on
In addition to configuring user log on, you can configure log on options using scripts and with
system tags.
Use the PostLogonDialog() script to show the InTouch Logon dialog box and return
TRUE.
Use the AttemptInvisibleLogin() to attempt logging in to InTouch using the supplied
credentials.
Use System Tags $OperatorEntered, $PasswordEntered and $OperatorDomainEntered
in a script to set the user name, password, and domain name. These tags are internal
message type tags that are intended for write operation only.
If the log on is successful, the $AccessLevel system tag is set to the predefined value associated
with the user in the InTouch security user list.
Log Off
Use the following scripting and system tag options to configure user log off options.
There are two topics pertinent to logging out of the InTouch security system:
Use the LogOff() script to set the current user status to the default None user.
Use the $OperatorEntered = “None” System Tag when you create a custom log on
window. You can link touch-sensitive input objects and QuickScripts to this tag to set the
user name for the logon.
Wonderware Training
Section 2 – Lock Down Your Application 9-33
When you log off your InTouch application using the Log Off option from Special | Security, the
User Name is reset to None with an Access Level of 0.
EnableDisableKeys() Function
You can write a script to enable or disable the Alt, Escape, and Windows system keys based on
the access level of the user logging in to WindowViewer. This is one way of securing your
application and preventing operators from closing an InTouch application in WindowViewer.
The details of the function are provided below.
Category
View
Syntax
EnableDisableKeys(AltKey, EscKey, WinKey);
Parameters
AltKey
Integer to enable or disable key filters for the Alt key:
1 = enable filter (disable Alt key)
0 = disable filter (enable Alt key)
EscKey
Integer to enable or disable key filters for the Escape key:
1 = enable filter (disable Esc key)
0 = disable filter (enable Esc key)
WinKey
Integer to enable or disable key filters for the Windows key:
1 = enable filter (disable Win key)
0 = disable filter (enable Win key)
Disabling the Alt key also disables the Win+L key combination (for locking the Windows desktop).
Win+L is the shortcut for another combination of keys that involves the Alt key. Disabling the Alt
key also disables the shortcut for locking the Windows desktop.
Disabling the Esc key disables it for all actions.
Examples of the functions you would use to disable/enable the keys are shown below:
Enable All Three Keys:EnableDisableKeys(0,0,0);
Disable All Three Keys:EnableDisableKeys(1,1,1);
Disable Windows Key only:EnableDisableKeys(0,0,1);
In virtual environments, such as those often used for classroom instruction, keystroke
combinations involving Alt, Esc, and Win are captured by the host operating system and not
passed through to the virtual environment. This makes it impossible to properly test all key
combinations. Quite often the affected key combinations include Ctrl + Shift + Esc for launching
Task Manager or Ctrl + Alt + Delete for OS Logon and OS Logoff or the Win key for calling Start
Menu appear unaffected by lockdown features. Consistently however, the Alt key will work in
combinations such as Alt + F for the WindowViewer File menu, or Alt + S for the WindowViewer
Special menu and may be tested faithfully within all virtual classroom environments.
Wonderware Training
Lab 24 – Locking Down Your Application 9-35
Introduction
In this lab you will configure automatic logoff and secure your application from unauthorized
access. When no user is logged into the application you will hide sensitive information from
unauthorized users, and restrict unauthorized access to the application using a variety of script
types. You will also modify the Menu window to hide the WindowViewer menu bar. Finally, you will
create a script to prevent the use of special access keys, including the Win and Alt keys.
Objectives
Upon completion of this lab, you will be able to:
Configure automatic logoff
Permit window navigation for authorized users
Hide menu access in WindowViewer
Select Home Windows for your application
4. Click OK.
5. Ensure only the Menu window is open.
Wonderware Training
Lab 24 – Locking Down Your Application 9-37
The automatic logoff Timeout is reset when a user clicks any part of WindowViewer.
9. Click Development!.
Automatic logoff will be turned off to prevent it from interfering with the remaining steps in this
course.
10. Close WindowViewer.
11. Open WindowViewer Properties, and set the Timeout field to 0 seconds.
Name: Home
Frame: checked
Window Type: Replace
Frame Style: Single
Title Bar unchecked
Size Controls: unchecked
Dimensions
X Location: 0
Y Location: 100
Window Width: 1800
Window Height: 910
The Window Properties dialog box will look like the following image.
Wonderware Training
Lab 24 – Locking Down Your Application 9-39
Next, you will configure the Home window to show when no user is logged in and restore a set of
windows when a user logs in.
17. In the Scripts pane, expand Data Change, and double-click $Operator.
18. In the script body insert the following script in front of Line 13.
Note: You may copy and paste the script from the C:\Training\Lab 24 - Locking Down
Your Application.txt file.
Show "Home";
ELSE
Show "KPI";
Show "Mixer";
Show "Current Alarms";
The modified script will look like the following image.
Wonderware Training
Lab 24 – Locking Down Your Application 9-41
Note: The WindowViewer Home Windows feature will be tested in a future lab.
Wonderware Training
Lab 24 – Locking Down Your Application 9-43
Note: Typically an application design would not have both a navigation combo box and
navigation buttons. But if it did, additional security would have to be added in the Menu
window to disable the SA_PageNavigation buttons such as Mixer or Current Alarms, but
these steps are not covered in this lab.
32. Click OK to save and close the Object Disabled -> Discrete Value dialog box.
33. Click OK to save and close the Animation Links dialog box.
Wonderware Training
Lab 24 – Locking Down Your Application 9-45
Y Location: -40
Window Height: 140
The Popup Window Type can cover the title bar and menu bar of WindowViewer, which are
located in the negative Y location of WindowViewer. The actual height of the Title Bar and
menu bar will differ depending on the theme and resolution of the windows environment.
43. Click OK.
Note: The labs in this course were intentionally limited to the screen space used for the
windows in the InTouch application. In your plant you would create your windows to take
advantage of maximum screen size, including multiple monitors.
Note: In virtual environments the host computer captures certain key combinations, and does not
pass these through to a virtual environment. If you are taking this course from a virtual machine,
you will need to use special shortcuts, or a virtual keyboard, to recreate these key combinations,
your instructor will provide these alternatives so you can test locking down keyboard access.
Wonderware Training
Lab 24 – Locking Down Your Application 9-47
48. Press the Ctrl + Shift + Esc keys, and verify you can open Task Manager.
From here, you could potentially end any process, including InTouch WindowViewer.
In virtual environments the host computer captures certain key combinations and does not
pass these through to the virtual environment. If you are taking this course from a virtual
machine, you will need to use special shortcuts to recreate these key combinations, your
instructor will provide these alternatives so you can test locking down keyboard access.
49. Close Task Manager.
50. Click Development!.
Wonderware Training
Lab 24 – Locking Down Your Application 9-49
Note: You may copy and paste the script from the C:\Training\Lab 24 - Locking Down
Your Application.txt file.
EnableDisableKeys(1,0,1);
Note: For the EnableDisableKeys() function a value of 1 disables a key whereas a value of 0
enables a key. Therefore, EnableDisableKeys(1,0,1) disables the ALT key and the WIN key on
the keyboard.
Note: You may copy and paste the script from the C:\Training\Lab 24 - Locking Down
Your Application.txt file.
This script enables the Alt, Esc, and Win keys when someone with an access level greater
than or equal to 8000 logs in. Users with an access level of 5000, but less than 8000, will have
access to the Win key.
62. Click OK.
Wonderware Training
Lab 24 – Locking Down Your Application 9-51
Note: Each user has access to different features. For example, karent and maryl have
different access than johnj.
Wonderware Training
Module 10 – Application Maintenance
Section 1 – Manage ArchestrA Symbols 10-3
Section 2 – Application Backup and Restore 10-5
Lab 25 – Backing Up and Restoring a Modern InTouch Application 10-7
10-2 Module 10 – Application Maintenance
Module Objectives
Describe application maintenance considerations
Describe how to back-up and restore a Modern InTouch application
Explain how NAD distributes a Modern InTouch application to a production
environment
Describe how to export and import ArchestrA symbols
Explain how to publish an InTouch application for runtime operators
Wonderware Training
Section 1 – Manage ArchestrA Symbols 10-3
Wonderware Training
Section 2 – Application Backup and Restore 10-5
Backing Up an Application
Backing up an application requires the use the Export button in the InTouch Application Manager.
The backup of the InTouch application is stored as an .aaPKG file, which is a generated Package
file from persisted data in the database. This file can be used to restore the application wherever
InTouch Application Manager is installed.
Restoring an Application
Restoring an application requires the use the Import button in the InTouch Application Manager.
Wonderware Training
Lab 25 – Backing Up and Restoring a Modern InTouch Application 10-7
Introduction
In this lab, you will close WindowMaker and back up your application to a location on your hard
drive. You will then restore the backup.
Objectives
Upon completion of this lab, you will be able to:
Back up your InTouch application
Restore your InTouch application
5. In the Export InTouch Application dialog box, navigate to C:\Training, and click Save.
The Export InTouch Application progress is displayed.
Wonderware Training
Lab 25 – Backing Up and Restoring a Modern InTouch Application 10-9
9. In the Open dialog box, navigate to C:\Training, and select InTouch Training
Application.aaPKG, and the click Open.
In the Application folder or file field, the path is displayed.
Wonderware Training
Lab 25 – Backing Up and Restoring a Modern InTouch Application 10-11
16. Select Restored Training Application, and on the toolbar, click the WindowViewer
button.
17. Verify the Restored Training Application opens in WindowViewer, and displays the Menu
and Home windows.
Note: The Menu and Home windows were configured as Home Windows in WindowViewer
properties in a previous lab.
Wonderware Training
Module 11 – Application Publishing and
Distribution
Section 1 – Application Publishing 11-3
Section 2 – Network Application Distribution 11-5
Lab 26 – Distributing an InTouch Application 11-9
11-2 Module 11 – Application Publishing and Distribution
Module Objectives
Explain publish to create stand-alone Intellectual Property protected copies of your
application
Explain how to configure NAD
Explain how NAD delivers changes to the Production machine
Wonderware Training
Section 1 – Application Publishing 11-3
Overview
Publishing an InTouch application converts the database of a Modern application into a traditional
file-based InTouch application. You can use a published version of your InTouch Application in
your production environment. A published application is a static release of the application, which is
no longer connected to WindowMaker and cannot reflect changes made to the original application
or any of its dependencies such as ArchestrA symbols. Published ArchestrA symbols cannot be
edited, which protects their intellectual property.
In essence, publishing your application extracts a copy of the application file and tables from the
application database and turns the application into a stand-alone, file-based application. Once in
this form, it can be zipped, copied to a Production node, and run from the InTouch Application
Manager.
Wonderware Training
Section 2 – Network Application Distribution 11-5
Overview
The Application Manager is used to configure Network Application Development (NAD), which is
two distinct technologies. The first is the ability to use the InTouch Application Manager to
remotely develop and edit an InTouch application that has its application directory shared. The
second is the ability of a WindowViewer client on a runtime Production node to monitor changes in
a shared InTouch master application directory. When the master application notifies clients a new
application is ready the changed application files are copied to a working folder on the Production
node and WindowViewer is restarted automatically.
What is NAD?
Network Application Development or NAD is an architecture that combines the best of the client-
based and server-based architectures. NAD provides automatic notification of application changes
and automatic distribution of the updated applications to View nodes. NAD can even be used to
automatically distribute master/slave applications.
Note: You cannot use the NAD features, if you are using WindowViewer as an NT service.
Advantages
Distributing the application
Single client application to maintain
View nodes automatically notified when application changes
Each node defines action to take on change
Unrestricted development of the application
Disadvantages
Distributing a large, complex application takes time
Limits flexibility of having different applications running on different nodes
Action Description
Ignore changes Causes the runtime (WindowViewer) node to ignore any
change made on the development node.
Restart WindowViewer The runtime node copies the updated master application
(if configured to do so) and then restarts WindowViewer
on the runtime node.
Prompt user to Restart Causes and interactive message box to appear, notifying
WindowViewer the operator that the application has changed. The
operation is asked if they want to restart WindowViewer.
Load Changes into Causes change made in the development node to
WindowViewer dynamically be loaded into WindowViewer. This may
affect performance for large updates.
Prompt user to load Cause an interactive message box to appear, notifying the
changes into operator that the application has changed. The operator is
WindowViewer asked if they want to load the changes to dynamically into
WindowViewer.
When the Ignore option is used or when a prompt option is used and the user declines an update,
NAD functionality can be handled manually. NAD provides the following tools used to customize
the update behavior of an application:
Tool Description
$ApplicationChanged provides an indication when a master application has changed. This
tagname could be used to cause a message to appear telling the operator that the master
application has changed.
You can also use the $ApplicationChanged system tagname in a data change script to build a
node update notification script. This script could include launching your own dialog boxes or
closing down certain processes. RestartWindowViewer() can then be used to initiate the
shutdown process.
RestartWindowViewer() This function will shut down and restart WindowViewer. It is used to
update an application when the automatic update Network Application Development (NAD)
functions are not used. This function can be used with $ApplicationChanged to determine when
a NAD update has occurred and then provide an update of the View node by shutting down and
restarting WindowViewer.
When using the Notify Clients command, the operator may want to delay the update until a later
time. This function can be placed in a touch Pushbutton Action QuickScript. Therefore, an operator
can perform an automatic shutdown and restart of WindowViewer when it is convenient. This
function has generally been superseded by the ReloadWindowViewer() function which updates
the View node without shutting down Viewer.
Wonderware Training
Section 2 – Network Application Distribution 11-7
Note: To use these functions, in the NAD Configuration dialog box, the When Application
Changes option must be set to: Ignore changes - do not restart. Setting this option prevents the
system from interfering with customized functions defined.
During application development, you can use the WindowMaker Special | Notify Clients
command to automatically update InTouch client applications. When this command is executed, a
flag is set to notify all remote View nodes that the master application has changed. These clients,
in turn, may automatically start an update process based on the parameters defined for each
node.
Note: If WindowMaker is abnormally shut down with an application loaded, the APPEDIT.LOK file
may not be automatically deleted. However, you can manually remove the lock by deleting the
APPEDIT.LOK file from the application directory.
For example, if you selected Section 1, “(Optional Path 1) InTouch History and Real-Time
Trending,” for InTouch Legacy history, which uses the HistData wizard, then the HistData I/O
Server would have to be running on every single Production node in order for that wizard to work.
Another example, each Production node instance of WindowViewer handles its own copy of alarm
information. If an operator on Production1 acknowledges an alarm, the same exact InTouch
application running on Production2 is not informed of that acknowledgment. Therefore, to
properly design a distributed alarm model, the plant would require a central WindowViewer node,
named a tag server, in order for each Production node to reflect the same alarm information.
Using a tag server, an operator on Production1 acknowledges an alarm on the tag server, and
Production2, which is listening to that same alarm on the tag server, will see the
acknowledgment. Detailed instructions on how to build and use a tag server are beyond the scope
of this course and are available in other learning resources, such as the help documentation.
Wonderware Training
Lab 26 – Distributing an InTouch Application 11-9
Introduction
In this lab, you will configure Network Application Development (NAD) to copy your application to a
Production node, similar to what an operator would use out in the field. You will then make
changes to the application and view how those changes affect the Production node.
Objectives
Upon completion of this lab, you will be able to:
Configure how WindowViewer will receive application updates
Configure NAD on the Production node
Distribute your application to the Production node
Notify clients of changes
3. Click Share.
Wonderware Training
Lab 26 – Distributing an InTouch Application 11-11
4. Click Done.
5. Close Windows Explorer.
The menu option Prompt to Notify Clients on Close is a toggle that, when enabled, will
prompt you to notify clients when WindowMaker is closed.
7. Switch to your Production node.
Note: Your instructor will provide the steps to connect and login to the Production node.
Wonderware Training
Lab 26 – Distributing an InTouch Application 11-13
17. In the Browse For Folder dialog box, Folder field, enter \\S01ENG\Training\InTouch
Training Application, where S01ENG is your Engineering node.
Note: Your instructor will provide the name of the Engineering node.
Wonderware Training
Lab 26 – Distributing an InTouch Application 11-15
Wonderware Training
Lab 26 – Distributing an InTouch Application 11-17
Wonderware Training
Module 12 – Web Client
Section 1 – Web Client 12-3
Lab 27 – Using the Web Client 12-9
12-2 Module 12 – Web Client
Module Objectives
Describe the Web Client features and dependencies
Explain how to enable the Web Client
Explain how to navigate graphics in the Web Client
Explain to use the Web Client fast switch
Wonderware Training
Section 1 – Web Client 12-3
This section will describe the Web Client features and dependencies.
Overview
The InTouch Web Client feature (Web Client) allows you to view specific ArchestrA graphics used
within an InTouch HMI application on any HTML5-supported web browser. A built-in web server
enables web browsers to access application graphics, from any Microsoft Windows client or server
operating system without the use of Remote Desktop Protocol (RDP) or Internet Information
Services (IIS) for Microsoft Windows Server. You can view application ArchestrA graphics in a web
browser for Modern and Managed applications only, Legacy applications are not supported.
When the Web Client is disabled, the InTouch Web service indicates a Manual startup type:
This tool in the InTouch Application Manager represents the Web Client enabled:
When the Web Client is enabled, the InTouch Web service is in Automatic startup type with a
status of Running:
Wonderware Training
Section 1 – Web Client 12-5
A single symbol within the Web Client Root Folder may be configured by enabling Set Web Client
Home Symbol. The Home symbol will be automatically selected and displayed when the InTouch
Web Client is accessed using a browser. Additionally, the Web Client interface provides a Home
button which may be used to display the Home symbol. The Home symbol is marked in the
ArchestrA Graphic Toolbox with a Home icon.
Element Description
1 The Title bar displays the InTouch application name, symbol name, home icon, notifications
icon, full screen icon, and profile icon.
2 Click the icon to view the folder navigation overlay. All folders and symbols under the selected
Web Client root folder are displayed.
3 The canvas area displays the symbol selected from the navigation overlay. The symbol will be
scaled to fit the browser viewport size, while maintaining the aspect ratio. The navigation and
notifications overlays do not consume any space on the canvas, or affect the size of the
graphic.
4 Click the Notifications icon to view the notifications related to connection and licensing issues.
Wonderware Training
Section 1 – Web Client 12-7
Known Limitations
A number of features common to InTouch HMI applications are not yet supported by the Web
Client. For example, no ActiveX or .NET controls, such as the Alarm Client, are supported at this
time. For a detailed list and description of known limitations with Web Client consult the PDF file
entitled: Viewing InTouch Application Graphics in a Web Browser.
Wonderware Training
Lab 27 – Using the Web Client 12-9
Introduction
In this lab, you will enable the Web Client server, which provides access to the Web Client feature.
In the ArchestrA Graphic Toolbox you will set the Home folder and Home symbol for the Web
Client. Then, you will use the Web Client fast switch to preview navigation and display graphics in
a browser.
Objectives
Upon completion of this lab, you will be able to:
Enable Web Client (starts a web site hosting service)
Set the Web Client Root folder
Set the Web Client Home Symbol
Use the Web Client fast switch to open the Web Client in the default web browser
Pan and zoom an ArchestrA graphic in a web browser using a mouse and keyboard
Navigate to different graphics using the Web Client
Use Navigation Search
Use the Hyperlink animation to call a specific symbol
Visualize alarms in Web Client
Identify write functionality not supported in Web Client
Modify a graphic in WindowMaker and observe the automatic refresh in the Web Client
The Enable Web Client button turns blue to indicate that it has been enabled.
Note: Starting WindowViewer with the Runtime fast switch enables the Web Client fast
switch in WindowMaker, and ensures WindowViewer is running so there will be data for the
Web Client.
Wonderware Training
Lab 27 – Using the Web Client 12-11
6. Click Development!.
7. Click the Web Client fast switch.
After a few moments, the default web browser opens, displaying the Web Client. The
examples that follow, use the Google Chrome browser.
Wonderware Training
Lab 27 – Using the Web Client 12-13
Notice the LABEL still uses the default string from the original library. By default, the Web
Client converts every symbol in the Graphic Toolbox to HTML5, without further configuration.
The majority of these symbols require further configuration to make them more usable.
13. Expand the intouch training application toolset, right-click KPI, and select Set Web Client
Home Symbol.
After a few moments, the default web browser opens, and the Home symbol appears.
Wonderware Training
Lab 27 – Using the Web Client 12-15
The Web Client displays the symbols in the Web Client root folder. In this example, the Root
folder contains only the KPI symbol.
Wonderware Training
Lab 27 – Using the Web Client 12-17
22. With the cursor hovering over the middle of the Mixer symbol, click and hold down the mouse
wheel, and move the mouse to pan the graphic.
23. Scroll the mouse wheel down to zoom out.
24. Click the Home button.
Wonderware Training
Lab 27 – Using the Web Client 12-19
The buttons at the bottom of the symbol are non-functional because the Web Client does not
support write functionality.
Because Web Client supports read-only functionality, this list primarily contains all of the write
functionality that is unsupported.
Wonderware Training
Lab 27 – Using the Web Client 12-21
27. Scroll to the bottom of the list and observe the last four rows.
Notice the four buttons in the Current Alarms symbol use write functionality that is not yet
supported.
29. In the Current Alarms symbol, click the Tag column header.
Wonderware Training
Lab 27 – Using the Web Client 12-23
36. In the Properties pane, Animations area, select Action Scripts and click Remove
Animations.
Wonderware Training
Lab 27 – Using the Web Client 12-25
Even without the Web Client interface, the graphic supports zoom and pan.
Wonderware Training