You are on page 1of 634

Revision AWonderware Training

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

InTouch HMI 2017


Update 3
INFORMATION IN THIS DOCUMENT IS SUBJECT TO CHANGE WITHOUT NOTICE.

Copyright © 2019 AVEVA Group PLC and its subsidiaries. All rights reserved.
Table of Contents 1

Module 1 Introduction .................................................................................1-1


Section 1 – Course Introduction......................................................................... 1-3
Section 2 – InTouch Software Overview............................................................ 1-9
Section 3 – System Requirements and Licensing ........................................... 1-11
Section 4 – InTouch Application Types............................................................ 1-13
Lab 1 – Creating the Modern InTouch Application........................................... 1-17

Module 2 Window Layout and Basic Navigation ......................................2-1


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

Module 3 InTouch Tagname Dictionary.....................................................3-1


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

Module 4 Situational Awareness Visualization.........................................4-1


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-97
Lab 10 – Building a Command Symbol.......................................................... 4-103

Module 5 InTouch Alarms ...........................................................................5-1


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

Module 6 Data Logging and Trending .......................................................6-1


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 – Inline Trending with Trend Pen ......................................................... 6-77

InTouch HMI (Standard Edition) 2017 Update 2


2 InTouch HMI (Standard Edition) 2017 Update 2

Module 7 Introduction to QuickScript ....................................................... 7-1


Section 1 – Introduction to InTouch QuickScript ................................................ 7-3
Lab 19 – Opening an Application with QuickScript .......................................... 7-17

Module 8 Introduction to ArchestrA Symbol QuickScript .NET ............. 8-1


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

Module 9 Security ....................................................................................... 9-1


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

Module 10 Application Maintenance ......................................................... 10-1


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

Module 11 Application Publishing and Distribution ................................ 11-1


Section 1 – Application Publishing ................................................................... 11-3
Section 2 – Network Application Distribution.................................................... 11-5
Lab 26 – Distributing an InTouch Application ................................................... 11-9

Module 12 Web Client ................................................................................. 12-1


Section 1 – Web Client..................................................................................... 12-3
Lab 27 – Using the Web Client......................................................................... 12-9

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

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.

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

InTouch HMI 2017 Update 3


1-4 Module 1 – Introduction

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.

Module 2 – Window Layout and Basic Navigation


Section 1 – WindowMaker Overview
This section will provide an overview of using WindowMaker.
Section 2 – WindowViewer Overview
This section will provide an overview of the InTouch runtime environment, WindowViewer.
Section 3 – Configure and Test Navigation Using WindowMaker
This section will provide an overview of how to use WindowMaker to embed symbols in
windows and apply animations to symbols. This section will also explain how to test
animations that will navigate to different windows in runtime.

Module 3 – InTouch Tagname Dictionary


Section 1 – The Tagname Dictionary
This section will explain tag types and the Tagname Dictionary.
Section 2 – I/O Configuration
This section will discuss the data acquisition components of InTouch.
Section 3 – Tag Viewer
This section will describe the Tag Viewer and will explain how to view, save, and import watch
windows. This section will also discuss dotfields, and explain how to interpret value, time, and
quality information in a watch window.
Section 4 – DBDump and DBLoad
This section will explain how to use the DBDump and DBLoad utilities for bulk handling of
InTouch tags.
Section 5 – Other Tag Management Utilities
This section will discuss the Cross Reference Utility and Tag use counts. It will explain how to
find and delete tags.

Module 4 – Situational Awareness Visualization


Section 1 – ArchestrA Symbols and Situational Awareness

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.

Module 5 – InTouch Alarms


Section 1 – InTouch Tagname Alarm Configuration
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.
Section 2 – Live Alarms Management
This section will describe alarm management, define alarm ack models, and discuss alarm
query syntax. This section will also explain of the .NET Alarm Client features, discuss alarm
inhibition, and compare alarm inhibition with alarm suppression.
Section 3 – Historical Alarms Management
This section will explain how to record alarms in a database and retrieve those alarms to view
in the Alarm Client.

Module 6 – Data Logging and Trending


Section 1 – (Optional Path 1) InTouch History and Real-Time Trending
Optional Path 1 has been written for legacy InTouch history users. Select this learning path to
learn how to use InTouch historical logging.
This section will discuss the built-in InTouch historical logging features. The features include
how to enable InTouch history, visualizing InTouch history, and using HistData for exporting
historical logs to .csv files. This section will go on to explain how to use the Trend Client .NET
control for real-time trending visualization.
Section 2 – (Optional Path 2) Using Historian with InTouch
Optional Path 2 has been written for Historian Server users. Select this learning path to learn
how to use Historian data with InTouch.
This section will explain how to import tags into Historian Server using the Tag Importer Wizard
in the ArchestrA System Management Console. The section will go on to describe how to build
a Historian Client Trend display in InTouch.
Section 3 – (Optional Path 1 and 2) Trend Pen
This section will use the Trend Pen to display both historical and live data.

Module 7 – Introduction to QuickScript


Section 1 – Introduction to InTouch QuickScript

InTouch HMI 2017 Update 3


1-6 Module 1 – Introduction

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 8 – Introduction to ArchestrA Symbol QuickScript .NET


Section 1 – Introduction to ArchestrA Symbol QuickScript.NET
This section will provide an overview of ArchestrA Symbol QuickScript.NET, and describe the
features and functions that are unique to each script type. This section will also explain the
QuickScript Editor.
Section 2 – Showraphic() and InTouch Windows
This section will explain a scalable method to navigate an InTouch application.
Section 3 – ShowGraphic() and ArchestrA Symbols
This section will explain a scalable method to navigate an InTouch application.

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.

Module 10 – Application Maintenance


Section 1 – Managing ArchestrA Symbols
This section will explain how to manage ArchestrA symbols including exporting, importing, and
restoring library symbols if accidentally deleted.
Section 2 – Application Backup and Restore
This section will explain how to export a Modern application to an .aaPKG file. This section will
go on to explain how to import a Modern application from an .aaPKG file.

Module 11 – Application Publishing and Distribution


Section 1 – Application Publishing
This section will explain how to publish your InTouch application for your production
environment.
Section 2 – Network Application Distribution
This section will explain how to configure Network Application Development (NAD) and how
NAD delivers changes to the production machine.

Module 12 – Web Client


Section 1 – Web Client
This section will describe Web Client features and dependencies.

Wonderware Training
Section 1 – Course Introduction 1-7

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.

Overview of InTouch Software


InTouch software provides graphic visualization of operations management and control.
Wonderware InTouch provides you with a quick and easy way to create HMI applications for
Microsoft operating systems. InTouch applications are used around the world in a variety of
industries such as food processing, semiconductors, oil and gas, automotive, chemical,
pharmaceutical, pulp and paper, transportation, and utilities.
The InTouch software is made up of three software components which allow you to create, design,
and run your InTouch applications. These three software components are: InTouch Application
Manager, InTouch WindowMaker, and InTouch WindowViewer.

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

InTouch HMI 2017 Update 3


1-8 Module 1 – Introduction

Wonderware Training
Section 2 – System Requirements and Licensing 1-9

Section 2 – 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.2).

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).

Operating System, .NET Framework, and Virtualization


Requirements
The following covers specific recommendations for the environment needed to support the
InTouch HMI 2017 software product.

.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.

InTouch HMI 2017 Update 3


1-10 Module 1 – Introduction

.NET 3.5 is installed only because the supported SQL Server versions require it. No other
dependencies must exist.

ActiveX Controls Behavior on Supported Windows Operating Systems


Due to the Data Execution Prevention (DEP) feature of Windows 7 and later operating systems,
any ActiveX control built with ATL version 7.1 or earlier will fail to host or will have unpredictable
behavior in InTouch HMI 2017 either in WindowMaker or WindowViewer.

Configuring Remote Alarm Retrieval Queries


The process to configure remote alarm retrieval queries has changed for interactive applications
such as InTouch when running on currently-supported Windows and Windows Server operating
systems.
When InTouch WindowViewer is started and generates alarms from an interactive Windows
desktop session, an AlarmViewer control (running within InTouch) on a remote node must be
specially configured to query the alarms. The source alarms will not appear unless the
AlarmViewer control's alarm query is configured.
This type of query only works for InTouch as an alarm provider running in a Terminal Services
session, not for InTouch running in a console session.

Product Name Components


WindowMaker WindowViewer
Microsoft Windows Desktop Y Y
Microsoft Windows Server Y Y
Microsoft .NET Framework Y Y

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

Protocols Secured or not Secured


The following protocols are either all secured or all are not secured:
 SuiteLink
 iData
 iBrowse
 HCAL
List of software which support secured communication:
 InTouch HMI 2017 Update 3 and later
 *OI Server
 InTouch Web Client in 2017 Update 3 and later
 Historian 2017 Update 3 and later
 Sentinel System Monitor 1.1 for System Platform 2017 Update 3 and later
*Communications from the specific OI Server to any other products listed above can be
encrypted. This is generic and applies to all OI Server versions.

InTouch HMI 2017 Update 3


1-12 Module 1 – Introduction

Node to Node Communication


Node-to-Node communication is unsecured under certain scenarios, including the following:
 The version of the software installed on one or more nodes is earlier than 2017 Update 3
(Communication Driver version has no impact)
 One node points to a System Management Server, but there is no System Management
Server configured on the other node
 There is no System Management Server configured for both nodes
Please note that if one node points to one System Management Server and the other node points
to another System Management Server, there will be NO network connection between the nodes.

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

Section 3 – InTouch Application Types


This section will provide an overview of the different types of InTouch applications.

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.

InTouch Application Types


For both convenience and specific usage, InTouch provides several application types that can be
used depending upon the need.

Legacy InTouch Application


Legacy applications, also named standalone, are for backward compatibility and support only
older rasterized graphic types and wizards native to the InTouch software.

Modern InTouch Application


This course will focus on creating, editing, and running a Modern InTouch application. Modern
applications combine all of the features of the legacy applications with the advanced capability of
vector-based ArchestrA graphics. Modern InTouch applications allow you to drag, drop, and
configure ArchestrA graphics into your windows without leaving the WindowMaker interface.
Throughout this course, you will develop a Modern InTouch application. The main software
component of InTouch used to create a Modern InTouch application is the InTouch Application
Manager.
Edit a Modern InTouch application by launching WindowMaker from the InTouch Application
Manager. WindowMaker allows you to create and configure OI access, tags, windows, graphics,
and make other application configuration changes.
You run a Modern InTouch Application by launching WindowViewer from either the InTouch
Application Manager or from WindowMaker directly. WindowViewer allows you to test and prove
your Modern Application design.

InTouch HMI 2017 Update 3


1-14 Module 1 – Introduction

Published InTouch Applications


A Published Modern application can be distributed like a Legacy InTouch application, but it will
continue to support ArchestrA symbol functionality. Modern InTouch applications are published
from Application Manager. However, you cannot edit a Published Modern application. If updates
are made to the source windows in WindowMaker, you must re-publish a Modern Published
application, to apply the edits.
Publishing an application accomplishes two key objectives: first, a published application does not
depend on a network connection to the Modern InTouch Application database, which allows it to
act like a stand-alone application. Secondly, publishing prevents tampering or editing, thus,
protecting the intellectual property and design of that application. However, this also means that a
published copy of a Modern Application can not serve as a backup of any kind, because you will
not be able to edit it.

Create Modern Applications

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.

Managed InTouch Applications


There is a fourth InTouch application type named a Managed InTouch application. It is not created
or managed using the InTouch Application Manager. Therefore, it is beyond the scope of the
discussion that will be included in this course. For additional information on Managed InTouch
application, please refer to the InTouch for System Platform training course.

Wonderware Training
Section 3 – InTouch Application Types 1-15

The WindowMaker Interface


The WindowMaker development environment allows an InTouch application developer to
configure most of the available user interface elements, such as toolbars, view panes, status bar,
classic and project view panes, and even the title and application directory path displayed in the
WindowMaker title bar.
You can turn off user interface elements to provide additional work space or rearrange the toolbars
and the view panes to suit your style and efficiency. You can also display the optional ruler, and
turn the visible grid on and off, which is used to accurately place graphical elements on an open
window. You can adjust the levels of undo supported by WindowMaker or change the spacing of
the visible grid.

WindowMaker Toolbars and Panes


The WindowMaker view panes provide hierarchical graphical views of application elements. These
views display the windows, scripts, menus, wizards and other items that have been configured in
the application, and provides easy access to them. They also provide quick access to many of the
most commonly used commands and functions in WindowMaker.
WindowMaker combines the Classic view and the Project view to show InTouch application
windows as well as the tools available for use. Like other toolbars, they can be hidden or shown,
and be docked with the WindowMaker application frame or undocked to float over the workspace.
The Project view allows you to create project folders to help you organize and manage application
elements. For example, creating a folder for Production Area which might contain all of the
windows that represent processes found in the Production Area. This makes finding what you are
looking for much easier in an application with hundreds of windows.

InTouch HMI 2017 Update 3


1-16 Module 1 – Introduction

Wonderware Training
Lab 1 – Creating the Modern InTouch Application 1-17

Lab 1 – Creating the Modern InTouch


Application

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

InTouch HMI 2017 Update 3


1-18 Module 1 – Introduction

Create the Modern InTouch Application


In the following steps, you will initialize and use the InTouch Application Manager to create a
Modern InTouch application.
1. Open InTouch Application Manager.
The Welcome to InTouch Application Manager dialog box appears.

2. Click Next.
The starting directory search screen appears.

3. Retain the default starting directory, and click Finish.

Wonderware Training
Lab 1 – Creating the Modern InTouch Application 1-19

The InTouch Application Manager appears.

Next, you will create a Modern InTouch application.


4. In the upper-left corner, click the New icon.

The Create New Application dialog box appears.

5. Retain the default selection, and click Next.

InTouch HMI 2017 Update 3


1-20 Module 1 – Introduction

6. In the application storage location field, enter C:\Training.

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.

10. Click Next.


The Name and Description fields appear. The name of the application given here will be
displayed in the InTouch Application Manager.
11. In the Name and Description fields, enter InTouch Training Application.

12. Click Finish.

InTouch HMI 2017 Update 3


1-22 Module 1 – Introduction

The application creation progress is displayed.

This will take a few moments.


When it is created, the new InTouch Training Application appears in the InTouch Application
Manager.

Wonderware Training
Lab 1 – Creating the Modern InTouch Application 1-23

Open the Modern InTouch Application


Next, you will open the new InTouch application in WindowMaker. Before opening the application,
you will configure the Lock Window Size setting. This will prevent graphics and windows from
being resized if the screen resolution changes.
13. Right-click the InTouch Training Application, and select Properties.

The Properties dialog box appears.

InTouch HMI 2017 Update 3


1-24 Module 1 – Introduction

14. In the Properties dialog box, check the Lock Window Size check box.

15. Click OK.


16. With the InTouch Training Application highlighted, click the WindowMaker button.

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

The InTouch Application Manager closes. After a moment, WindowMaker opens.

17. On the WindowMaker Special menu, select Configure | WindowMaker.

InTouch HMI 2017 Update 3


1-26 Module 1 – Introduction

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.

18. Click Cancel.

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

Section 1 – WindowMaker Overview


This section will provide an overview of using WindowMaker.

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.

InTouch HMI 2017 Update 3


2-4 Module 2 – Window Layout and Basic Navigation

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.

InTouch Window Layout


Build a window portal by arranging windows of various sizes and position to create a single display
for the application. This allows a mix of windows that can be designated for different purposes,
such as a menu window, a content window, an overview window, and an auxiliary information
window. Fixed windows, such as menu windows or overview windows, rarely change and can
remain in place in the overall display. Conversely, content windows, such as P&ID displays or
auxiliary displays, are used for frequently changing content and can be quickly switched to display
new areas of a process or facility.
While windows remain open they continue to update data being displayed and consume system
resources such as CPU and RAM resources to process scripts and animation. This is true even if
the window is open but not visible on the screen. For content windows, the Replace window type is
used to close the window that it covers in order to free up system resources. This will allow peak
efficiency with the use of system resources and maintain maximum performance of the CPU and
RAM.

Embedding an ArchestrA Graphic on an InTouch Window


You can embed prebuilt symbols in application windows from the ArchestrA Graphic Toolbox.
There are two ways to embed an ArchestrA graphic into a window:
 Drag and drop an ArchestrA graphic from the ArchestrA Graphic Toolbox directly onto
the window

 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

Adding the ShowWindow Animation to an ArchestrA Graphic


The simplest form of window navigation is the use of buttons configured to open a window. The
buttons are configured by adding a ShowWindow animation to open a specific window. Multiple
buttons are organized together on a window to allow users to navigate the application. In runtime
when the operator clicks the navigation button the selected window will open. In runtime when the
operator clicks the navigation button the selected window will open.

Switching Between Development and Runtime


The menu in both WindowMaker and WindowViewer provides a switch named the FastSwitch.
The FastSwitch allows application developers to test what they have designed in WindowMaker in
the WindowViewer runtime environment.

Configuring Custom Properties and Wizard Options


As part of the Situational Awareness Library in the graphic toolbox, the symbols selected contain
thousands of configurable options. Wizard Options allow you to configure these options. For
example, a single ArchestrA pump symbol includes dozens of visual configurations. Situational
Awareness Library symbols are designed to leverage these Wizard Options to configure the look
and behavior of the final graphic in runtime.

InTouch HMI 2017 Update 3


2-6 Module 2 – Window Layout and Basic Navigation

Wonderware Training
Section 2 – WindowViewer Overview 2-7

Section 2 – WindowViewer Overview


9
This section will provide an overview of the InTouch runtime environment, WindowViewer.

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.

InTouch HMI 2017 Update 3


2-8 Module 2 – Window Layout and Basic Navigation

Wonderware Training
Section 3 – Configure and Test Navigation Using WindowMaker 2-9

Section 3 – Configure and Test Navigation Using WindowMaker


This section will provide an overview of how to use WindowMaker to embed symbols in windows
and apply animations to symbols. This section will also explain how to test animations that will
navigate to different windows in runtime.

Embed an ArchestrA Graphic in a Window


There are several methods of placing a graphic from the ArchestrA Graphic Toolbox into a window
in WindowMaker. The simplest of these methods is to drag and drop the graphic from the
ArchestrA Graphic Toolbox onto the window.
Symbols embedded on a window contain all of the built-in functionality, which is accessible by
double-clicking to configure features.

Apply InTouch Animations to ArchestrA Graphics


After a graphic has been added to a window from the ArchestrA Symbol Library, an InTouch
animation can be applied. After an InTouch animation has been applied, any built-in interactive
functionality is disabled and replaced by the InTouch animation. InTouch animations can be used
to create navigation buttons using Show Window and Hide Window animations. These
animations allow you to select one or more windows, which can be controlled when the operator
clicks the graphic to which the animation was applied.

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.

InTouch HMI 2017 Update 3


2-10 Module 2 – Window Layout and Basic Navigation

Wonderware Training
Lab 2 – Setting Up Windows and Navigation 2-11

Lab 2 – Setting Up Windows and Navigation

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

InTouch HMI 2017 Update 3


2-12 Module 2 – Window Layout and Basic Navigation

Create the Layout Windows


In the following steps, you will create windows and position them to create a basic window layout
that will be used throughout this course.
1. On the WindowMaker File menu, select New Window.

The Window Properties dialog box appears.


2. In the Name field, enter Menu.

Wonderware Training
Lab 2 – Setting Up Windows and Navigation 2-13

3. In the Window Type area, select Popup.

4. Uncheck the Title Bar check box.

InTouch HMI 2017 Update 3


2-14 Module 2 – Window Layout and Basic Navigation

5. Configure the Dimensions area as follows:

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

7. On the File menu, select New Window.


The Window Properties dialog box appears with the settings from the Menu window,
configured previously.

8. In the Name field enter KPI.


9. Configure the Dimensions area as follows:

X Location: 0
Y Location: 100
Window Width: 350
Window Height: 580

10. Click OK.

InTouch HMI 2017 Update 3


2-16 Module 2 – Window Layout and Basic Navigation

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

13. In the Window Type area, select Replace.


14. Check the Title Bar check box.

15. Check the Template check box.

InTouch HMI 2017 Update 3


2-18 Module 2 – Window Layout and Basic Navigation

16. Configure the Dimensions area as follows:

X Location: 350
Y Location: 100
Window Width: 1450
Window Height: 580

17. Click OK.


The Content_NonFrame window is listed under the Template Windows folder in the
Windows & Scripts pane, and is open below the Menu window on the canvas.

Wonderware Training
Lab 2 – Setting Up Windows and Navigation 2-19

18. On the File menu, select New Window.


19. In the Name field, enter Content_Frame.
20. Check the Frame check box.

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.

InTouch HMI 2017 Update 3


2-20 Module 2 – Window Layout and Basic Navigation

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.

The Content_Frame window closes.

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.

The Content_NonFrame window closes.


25. On the File menu, select New Window from Template.

InTouch HMI 2017 Update 3


2-22 Module 2 – Window Layout and Basic Navigation

The Template Window Browser appears.

26. In the Template Browser Window, select Content_Frame.

27. Click OK.

Wonderware Training
Lab 2 – Setting Up Windows and Navigation 2-23

The Window Properties dialog box opens.

Notice that Template is not checked because this is a window created from a Template window.
28. In the Name field, enter Mixer.

29. Click OK.


The Mixer window appears.

InTouch HMI 2017 Update 3


2-24 Module 2 – Window Layout and Basic Navigation

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.

31. Click OK.

Wonderware Training
Lab 2 – Setting Up Windows and Navigation 2-25

The canvas will look like the following image.

InTouch HMI 2017 Update 3


2-26 Module 2 – Window Layout and Basic Navigation

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.

InTouch HMI 2017 Update 3


2-28 Module 2 – Window Layout and Basic Navigation

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.

Note: Do NOT close the Current Alarms window at this time.

Wonderware Training
Lab 2 – Setting Up Windows and Navigation 2-29

Embed and Configure the Menu Graphics


Next, you will embed graphics and configure them to switch between the Mixer, Current Alarms,
and Historical Alarms and Events windows in runtime.
37. In the ArchestrA Graphic Toolbox, expand Situational Awareness Library \ Input.

38. Drag SA_PageNavigation to the left side of the Menu window.


An instance of SA_PageNavigation is embedded in the Menu window.

InTouch HMI 2017 Update 3


2-30 Module 2 – Window Layout and Basic Navigation

39. In the Menu window, right-click the embedded instance, and select Substitute | Substitute
Strings.

The Substitute Strings dialog box appears.


40. In the New String field, enter Mixer.

41. Click OK.


The label of the embedded instance changes to Mixer.

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.

InTouch HMI 2017 Update 3


2-32 Module 2 – Window Layout and Basic Navigation

The Animation Links dialog box appears.


45. In the Animation Links dialog box, click Show Window.

The Windows to Show when touched dialog box appears.


46. Check the Mixer check box.

Wonderware Training
Lab 2 – Setting Up Windows and Navigation 2-33

47. Click OK.


48. In the Animation Links dialog box, click OK.

The symbol is now a button that opens the Mixer window when clicked at runtime.

InTouch HMI 2017 Update 3


2-34 Module 2 – Window Layout and Basic Navigation

49. Ensure the Mixer button is selected, then right-click and select Duplicate.

A duplicate button appears.

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.

53. Click OK.


54. Right-click the Alarms button and select Animation Links.
55. In the Animation Links dialog box, click Show Window.
56. In the Windows to Show when touched dialog box, uncheck the Mixer check box, and
check the Current Alarms check box.

57. Click OK.


58. In the Animation Links dialog box, click OK.
59. Repeat the previous steps to create a third button labeled Events, with a Show Window
animation link to the Historical Alarms and Events window.
The Menu window will appear similar to the following image.

InTouch HMI 2017 Update 3


2-36 Module 2 – Window Layout and Basic Navigation

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

61. Close the Mixer window.

The Mixer window closes.

62. In the Menu window, click the Mixer button.


The Mixer window appears.

InTouch HMI 2017 Update 3


2-38 Module 2 – Window Layout and Basic Navigation

63. In the Menu window, click the Events button.


The Replace behavior has closed the Current Alarms window and opened the Historical
Alarms and Events window in its place.

Wonderware Training
Lab 2 – Setting Up Windows and Navigation 2-39

64. In the Menu window, click the Alarms button.


The Current Alarms window replaces the Historical Alarms and Events window.
65. In the upper-right corner of WindowViewer, click Development! to return to WindowMaker.

66. Right-click the WindowViewer icon on the task bar and select Close window.

WindowViewer closes.

InTouch HMI 2017 Update 3


2-40 Module 2 – Window Layout and Basic Navigation

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

Section 1 – The Tagname Dictionary


This section will explain tag types and the Tagname Dictionary.

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, I/O Tags, and $System Tags


InTouch data tags, which include discrete, integer, real, and message, are categorized as either
memory tags or I/O tags. Additionally, the dictionary has predefined tags named $System tags
that have very useful built-in functionality, such as Date and Time information.
For I/O tags, WindowViewer acts like an I/O client and requests or writes data to an external I/O-
aware application, such as an OI Server, DA Server, and OPC Server. WindowViewer can act as
an I/O server supplying I/O values to requesting clients from both $System tags, memory tags and
I/O tags defined in the Tagname Dictionary.

InTouch HMI 2017 Update 3


3-4 Module 3 – InTouch Tagname Dictionary

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.

Special Purpose Tag Types


There are several special tag types that perform complex functions, such as creating dynamic
alarm displays, historical trends, monitoring or controlling the tag that each historical trend pen is
plotting, and so on.

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.

Tag Naming Conventions


When creating tagnames, consider the following naming conventions:
 The maximum length is 32 characters
 Spaces are not permitted
 If you start with a number, do not follow with another number or a function character
 The backlash character “\” is reserved for SuperTags
 You must use at least one alpha character

InTouch HMI 2017 Update 3


3-6 Module 3 – InTouch Tagname Dictionary

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

Select Tag Dialog Box


To change the tag in the Tagname Dictionary, use the Select button to open the Select Tag dialog
box. The Select Tag dialog box displays all tags contained within the Tagname Dictionary. This is
also known as the Tag Browser. This is the primary tool used to view and select local and remote
tagnames and tagname dotfields from applications, or any other tag source that supports the
Tagname Dictionary interface. It enables selection of existing tags, addition of new tags and
viewing of basic Tagname Dictionary information.
The Tag Browser is also used to access the Tag Editor to perform editing, replication, and
configuration of remote references for remote tag sources. The first time the Tag Browser is
accessed, by default, <local> is selected for the tag source. This means that the tagnames in the
local application Tagname Dictionary are displayed. Thereafter, the most recently accessed tag
source tagnames are displayed.
The Tag Browser operates in either Dictionary or Selection mode. The mode is determined by
the method used to access it.

InTouch HMI 2017 Update 3


3-8 Module 3 – InTouch Tagname Dictionary

Configuring Tags
The following configuration options are available in the Tagname Dictionary.

Group
The Group button assigns the tag to a specific Alarm Group.

Read Only and Read Write


Read Only and Read Write are used to set write restrictions for I/O tags.

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.

InTouch HMI 2017 Update 3


3-10 Module 3 – InTouch Tagname Dictionary

Wonderware Training
Lab 3 – Defining Memory Tags 3-11

Lab 3 – Defining Memory Tags

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

InTouch HMI 2017 Update 3


3-12 Module 3 – InTouch Tagname Dictionary

Use the Tagname Dictionary to Create Tags


In the following steps, you will open the Tagname Dictionary, and define memory tags.
1. On the WindowMaker Special menu, select Tagname Dictionary.

The Tagname Dictionary dialog box appears.


2. Click New.

Wonderware Training
Lab 3 – Defining Memory Tags 3-13

3. In the Tagname field, enter Tag_Discrete1.

4. Click Type.

The Tag Types dialog box appears.


5. Check the Memory Discrete check box.

6. Click OK.

InTouch HMI 2017 Update 3


3-14 Module 3 – InTouch Tagname Dictionary

The Memory Discrete tag type displays to the right of the Type button.

7. In the Comment field, delete AccessLevel.

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.

10. Retain all of the defaults, and click Save.


11. Click New.
12. In the Tagname field, enter Tag_Integer.

InTouch HMI 2017 Update 3


3-16 Module 3 – InTouch Tagname Dictionary

13. Click Type.


14. In the Tag Types dialog box, check the Memory Integer check box.

15. Click OK.


16. In the Tagname Dictionary, click Save.
17. Repeat the previous steps to create another tag and configure it as follows:

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.

18. Click Save.

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.

InTouch HMI 2017 Update 3


3-18 Module 3 – InTouch Tagname Dictionary

Wonderware Training
Section 2 – I/O Configuration 3-19

Section 2 – I/O Configuration


This section will discuss the data acquisition components of InTouch.

System Platform Management Console


The System Platform Management Console, or ArchestrA System Management Console (SMC),
provides application diagnostics. The SMC can be used to configure historians and operations
integration (OI) servers, as well as view system messages, warnings, and errors. Additionally, the
SMC can remotely connect and perform these same tasks on other nodes on the network.

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.

InTouch HMI 2017 Update 3


3-20 Module 3 – InTouch Tagname Dictionary

Navigating the OI Server Manager


Within the SMC the OI Server Manager has a hierarchical tree of items named the Console Tree,
and a configuration pane named the Details pane. The configuration pane on the right, also
named a faceplate, will vary depending on the type of OI Server being configured. The OI Server
Manager has one or more node groups in its hierarchy and each node group comprises one or
more nodes. A node represents a computer that hosts at least one OI Server.

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.

Configuring the OI Server


The Configuration node is used to configure an OI Server for runtime. The Configuration node has
two functions. First, it has several global parameters that can be configured to adjust the OI Server
runtime performance. These parameters apply to all server instances in the server group.
Second, the Configuration node has its own hierarchy of configurable objects. Each object
represents a physical device, such as a channel, port, bridge, or PLC. Some OI Servers have two
levels of objects in the hierarchy. For example, a parent object may represent a network channel,
port, or bridge, while a child object may represent an individual device on that network.

Configuring Global Parameters


Each OI Server has a unique set of parameters that you can configure for an environment. These
parameters are unique to each type of field device, such as a PLC. For descriptions of these
configuration parameters see your OI Server-specific documentation.
Using the OI Server Manager, you can also configure a set of common or global parameters for
each OI Server. For example, the IP address of the device you are connecting to.

Configuring Device Groups


Device groups are labels used by client applications when accessing the OI Server.
The Device Group Update Interval determines how often the OI Server polls the device and sends
data to the client application. If this is not specified, all unnamed device groups have an update
interval of 1,000 milliseconds. If you configure multiple device groups with different update
intervals, the client application can receive data at various intervals.
Smaller update intervals quicken the turnaround for data changes and a increase overhead
because a large amount of data is being transmitted between the device and the OI Server. Large
update intervals slow turnaround for data changes.

InTouch HMI 2017 Update 3


3-22 Module 3 – InTouch Tagname Dictionary

Configuring Device Items


Defining device items provides a more user-friendly way to name data in the device. Defining
device items is optional. Use device items to access data in the OI Server and devices connected
to the OI Server. Device items consist of two pieces: a name and an item reference. After it is
defined in the OI Server, you can access it in the client program either through item name or the
item reference. The device Item name is an alternative name for the item reference. It is an alias,
or a label, for the data in the device. You can use this label instead of the item reference when you
create the client application.
The item reference identifies data in the device. The item reference is a PLC memory reference.
Each device’s memory reference can have a different format. For more information, see your OI
Server specific documentation. The actual item reference can be entered as the device Item
name. In this case, the item reference value can be left empty.
You can add device items while the OI Server is active, and these new items are immediately
available to client applications.
You can make changes to items while the OI Server is active. Changes take effect immediately.
OPC clients that are already connected to the item are not affected until they release and re-
acquire the item.

Activating the OI Server


After the configuration of the OI Server is complete, and the changes have been saved, the OI
Server can then be activated. There are several modes of activation. These modes are Auto
Service, Manual Service, and Not a Service.
Running the OI Server as a service allows the OI Server to start automatically when the operating
system starts, without the presence of a human user to log in. This is a good mode for disaster
recovery or following server restarts. The final step is to perform the activation which runs the OI
Server. After an OI Server runs as an auto or manual service, it stays running until stopped in the
OI Server Manager or the computer shuts down.

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

Troubleshoot using the Log Viewer


The following is an example of the thought process behind tracking down a problem with InTouch.
First you will gather as much information first about the process that is malfunctioning. For
instance, you attempt to open WindowMaker and an error message is displayed. Note the text of
the message you received for keywords that you can search on later.
Next, you will open SMC and access the Log Viewer. Look for red and yellow messages. Also, use
the text and keywords you collected earlier about the failed process to search for clues in the
logged messages.
Lastly, you will use the Find command from the SMC to single out key words and text indicating the
source of the problem. You may also use the Filter command to reduce the number of messages
displayed and narrow your search. The Filter may also be used to set a time range for the
messages displayed.
This approach with these tools will assist you to rapidly identify the cause of issues so that you can
resolve them to stabilize your environment.

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.

InTouch HMI 2017 Update 3


3-24 Module 3 – InTouch Tagname Dictionary

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.

InTouch Access Names


You must associate InTouch I/O tags with an Access name. An Access name defines a
communication link with another I/O data source. Each Access name specifies an external I/O
source consisting of a node name, an application name, and a topic. When you create I/O tags,
you must associate them with an Access name in the definition of the tag.

Creating an Access Name


An Access name includes a form that allows you to specify the external I/O source. The following
table shows the entries that must be completed for the Access name.

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.

Defining I/O Tags


An I/O tag is different from a Memory tag because it requires both an Access name and an I/O
Item name. The Access name covers the first three of four parts: node, application, and topic. The
Item name covers the fourth, which is the PLC Memory Address, or data register, of the field
device.
There is a feature that allows you to use the tagname as the Item name and this is acceptable if
the manufacturer of the field device only requires characters which are supported by InTouch

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).

Runtime I/O Access


At runtime WindowViewer uses the four I/O address pieces: node, application, topic, and item to
remotely connect to the OI Server and retrieve data. For example, if the application name is
Microsoft Excel, the topic name is the name of the spreadsheet that contains the data, and the
Item name is the identification of the cell on the spreadsheet where the date is written to or read
from.
WindowViewer also acts as an I/O server. When an I/O-aware Windows application requests data
from WindowViewer using the appropriate connection syntax, WindowViewer will serve that data
to the requesting client. For example, in Microsoft Excel the following formula entered into a cell of
the spreadsheet will connect to WindowViewer on the local node and retrieve the current seconds
of the internal clock as seen by WindowViewer:
=VIEW|TAGNAME!'$Second’

InTouch HMI 2017 Update 3


3-26 Module 3 – InTouch Tagname Dictionary

Wonderware Training
Lab 4 – Configuring the Communication Driver 3-27

Lab 4 – Configuring the Communication


Driver

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

InTouch HMI 2017 Update 3


3-28 Module 3 – InTouch Tagname Dictionary

Configure the Communication Driver in the System Management


Console
In the following steps, you will use the System Platform Management Console (SMC) on your
Engineering node to remotely configure the Operations Integration Server Manager on your
Production node. The Operations Integration Server Manager will link to the Modbus simulator that
has already been installed on the Production node.
1. On your Engineering node, open the System Platform Management Console.
Once started, the dialog box will be labeled SMC - ArchestrA System Management
Console.
2. In the left pane, expand Operations Integration Server Manager.
3. Expand Default Group.
4. Right-click Default Group, and select New \ Node.

The New Node dialog box appears.


5. In the Node Name field, enter the name of the remote Production node where the OI Server is
installed.

Note: Your instructor will provide the name of the Production node.

6. Click OK.

Wonderware Training
Lab 4 – Configuring the Communication Driver 3-29

7. Expand the Production node name.

8. Expand OI.MBTCP.1, and click Configuration.

InTouch HMI 2017 Update 3


3-30 Module 3 – InTouch Tagname Dictionary

9. Right-click Configuration, and select Add TCPIP_PORT Connection.

10. Rename New_TCPIP_PORT_000 to PORT1.

Wonderware Training
Lab 4 – Configuring the Communication Driver 3-31

11. Right-click PORT1, and select Add ModbusPLC Connection.

12. Rename New_ModbusPLC_000 to PLC1.


In the right pane, you will see the PLC1 Parameters tab.

InTouch HMI 2017 Update 3


3-32 Module 3 – InTouch Tagname Dictionary

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

Import the Device Item Definition List


Next, you define a Device Group, which specifies the polling rate of the OI Server. Then you will
import a Device Item definition list that has been preconfigured in a .csv file. This list contains
aliases for PLC register addresses.
14. Click the Device Groups tab, right-click inside the table, and then select Add.

15. In the Name column, enter Topic1.

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.

InTouch HMI 2017 Update 3


3-34 Module 3 – InTouch Tagname Dictionary

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

Activate the OI Server


Finally, you will use the SMC to activate the OI Server connection.
20. Right-click OI.MBTCP.1, and select Activate (Auto start after reboot).

The OI.MBTCP.1 server is activated.


Prior to activation, the server is marked with a white x inside of a red border.

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.

21. Close the SMC.

InTouch HMI 2017 Update 3


3-36 Module 3 – InTouch Tagname Dictionary

Wonderware Training
Lab 5 – Creating I/O Access and I/O Tags 3-37

Lab 5 – Creating I/O Access and I/O Tags

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

InTouch HMI 2017 Update 3


3-38 Module 3 – InTouch Tagname Dictionary

Create an Access Name


In the following steps, you will create an Access name, which allows you to access I/O data using
tags that will be created later in this lab.
1. On the WindowMaker Special menu, select Access Names.

The Access Names dialog box appears.


2. Click Add.

The Add Access Name dialog box appears.

Wonderware Training
Lab 5 – Creating I/O Access and I/O Tags 3-39

3. In the Access Name field, enter PLCSim.

4. In the Node Name field, enter the name of the Production node where the PLC simulator is
running.

Note: Your instructor will provide the name of this computer.

5. In the Application Name field, enter MBTCP.


6. In the Topic Name field, enter Topic1.

7. Leave the remaining default settings and click OK.

InTouch HMI 2017 Update 3


3-40 Module 3 – InTouch Tagname Dictionary

PLCSim appears in the Access Names list.

8. Click Close.

Define I/O Tags in the Tagname Dictionary


Next, you will create and define tags to access I/O data.
9. On the Special menu, select Tagname Dictionary.
10. In the Tagname Dictionary, click New.
11. In the Tagname field, enter Mixer100_Pump1_CMD.

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.

13. Click OK.


Notice the definition defaults to Read Write which is appropriate for this tag which will be used
to stop and start a pump.

14. Click Access Name.

InTouch HMI 2017 Update 3


3-42 Module 3 – InTouch Tagname Dictionary

The Access Names dialog box appears.


15. Select PLCSim.

16. Click Close to select the PLCSim Access name.


PLCSim displays next to the Access Name button.

17. Check the Use Tagname as Item Name 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

18. Click Save.


19. Click New.
The Tagname automatically increments to Mixer100_Pump2_CMD.
The Item field automatically updated to match the Tagname because Use Tagname as Item
Name is checked.

20. Click Save.


21. Click New.
22. In the Tagname field, enter Mixer100_Pump1_PV.

InTouch HMI 2017 Update 3


3-44 Module 3 – InTouch Tagname Dictionary

23. Select the Read only option.

24. Click Save.


25. Create another tag named Mixer100_Pump2_PV.

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

Next, you will define analog I/O tags.


26. Create another tag named Mixer100_Temperature_PV.
27. Change the Type to I/O Real.
Notice the Details pane of the Tagname Dictionary changed because the Type has been set
to I/O Real.

28. Configure the Tagname Dictionary as follows:

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

29. Change the Access Name to PLCSim.

30. Click Save.

InTouch HMI 2017 Update 3


3-46 Module 3 – InTouch Tagname Dictionary

31. Create another I/O Real tag and configure it as follows:

Note: In the Tagname field, you will need to change Mixer101 to Mixer100.

Tagname: Mixer100_Level_PV
Max EU: 1000
Eng Units: Gallons

32. Click Save.

Wonderware Training
Lab 5 – Creating I/O Access and I/O Tags 3-47

33. Create another tag and configure it as follows:

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

34. Click Save.


35. Click New, and click Save to create the Mixer100_Inlet2_Position tag.
36. Click New, and in the Tagname field, enter Mixer100_Outlet_Position.

InTouch HMI 2017 Update 3


3-48 Module 3 – InTouch Tagname Dictionary

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

Section 3 – Tag Viewer


This section will describe the Tag Viewer and will explain how to view, save, and import watch
windows. This section will also discuss dotfields, and explain how to interpret value, time, and
quality information in a watch window.

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.

Enable and Start Tag Viewer


Enable Tag Viewer using the WindowViewer Properties form WindowMaker.
You can also configure the WindowViewer menu so that the Tag Viewer option can be selected an
launched from the Special menu at runtime. Tag Viewer can also be launched from a script named
LaunchTagViewer().
The Tag Viewer window contains three parts:
 The left pane, which displays the tags in a hierarchical structure, based on their alarm
groups
 The right pane, which displays the list of all available dotfields for the tag or alarm group
selected on the left pane
 The watch window at the bottom, which displays the live runtime values of tags that you
want to monitor.
 The Value, Timestamp, and Quality columns that represent Value Time Quality (VTQ) I/
O data monitoring, display if the data you are receiving is good and how to identify data
related problems.

Adding Tagnames to Watch window


The watch window is displayed at the bottom of the Tag Viewer by default. You can use this
window to view the value of tags at runtime. You can create additional watch windows to group
relevant tags together. You can also remove a watch window, if required.

InTouch HMI 2017 Update 3


3-50 Module 3 – InTouch Tagname Dictionary

Using Tag Viewer


You can assign tags to a watch window to view current tag values. You can add tags using several
methods.
 Right-click a tag and select Add to Watch
 Click a tag and drag it to the watch window
 Double-click a tag

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.

VTQ Dotfields (.fields)


The watch window of the Tag Viewer displays diagnostic information for I/O tags. This is
represented in the watch list by columns named Value, Time, and Quality. The information
contained in these columns comes directly from dotfields of properties from each I/O tag. These
three dotfields together are referred to as VTQ, an industry term that represents the diagnostic
quality of a tag.
VTQ places a time stamp and quality indicator on all data values delivered to VTQ-aware clients.
VTQ provides indicators of data quality useful for diagnostics and troubleshooting.

Value: .Value field is the tag value.


Time: .Time fields represent the last update time for the tag.
Quality: .Quality fields contains a code that represents the health of the tag.

.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.

InTouch HMI 2017 Update 3


3-52 Module 3 – InTouch Tagname Dictionary

Cannot Convert (.Quality of 64)


 The communications link has been verified
 The PLC understood the poll request and returned a valid response packet
 The data from the PLC could not be converted into the desired format
Possibilities for cannot convert include, but are not limited to:
 The server may return a constant in place of the data or return quality information alone
 The data is not usable
 It is not known whether the value is too large or too small
 The data returned from the PLC is of the incorrect data type
 A floating point number is returned, but is not value (for example: Not A Number)
Example: The value of 0x000A is returned from a BCD register in a PLC.
Communications Failed (.Quality of 24)
Any combination of the following:
 Data communications are down
 The topic is in slow poll (or equivalent) mode
 There have been no link validating messages
 Lack of resources in the server
For example, a TSR (or driver) cannot allocate memory.
 Lack of resources in the communications link
 The communications link is offline
 All communications channels are in use
 The network is unable to route the message to the PLC
Example: Attempting to read data from a PLC that has been powered off.
Cannot Access Point (.Quality of 4)
 The communications link has been verified
 The PLC understood our poll request and returned a valid response packet
 The PLC reported that it could not access the requested point
Possibilities for lack of accessibility include, but are not limited to:
 Item does not exist in PLC memory
 Item is not currently available (locked in some way due to resource contention)
 Item is not of the correct format/data type
 A write attempt was made, but item is read-only
 In most cases, a group of items will be affected when one item is invalid. This is due to the
block-polling scheme used by the servers
For example, if one item in a block of 10 is invalid, and then the entire block is marked
invalid by the PLC. The Server will report invalid quality for all items in the block.
 The data is unusable
Example: Attempting to read R40001, but R40001 is not defined in the PLC's memory map.

Wonderware Training
Section 3 – Tag Viewer 3-53

Saving Watch windows


You can create multiple watch lists and save them for later viewing. You can also rename a watch
list. Your watch window can contain multiple tabs, or watch lists, to help you organize your watched
tag lists.

InTouch HMI 2017 Update 3


3-54 Module 3 – InTouch Tagname Dictionary

Wonderware Training
Lab 6 – Watching Tags with Tag Viewer 3-55

Lab 6 – Watching Tags with Tag Viewer

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.

InTouch HMI 2017 Update 3


3-56 Module 3 – InTouch Tagname Dictionary

Monitor Tags Using Tag Viewer


In the following steps, you will enable Tag Viewer for use in WindowViewer. In WindowViewer, you
will launch Tag Viewer and add tags to the watch list to monitor the I/O data coming from the PLC
simulator.

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.

1. On the WindowMaker Special menu, select Configure | WindowViewer.

Wonderware Training
Lab 6 – Watching Tags with Tag Viewer 3-57

The WindowViewer Properties dialog box appears.


2. On the General tab, check the Enable Tag Viewer check box.

InTouch HMI 2017 Update 3


3-58 Module 3 – InTouch Tagname Dictionary

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

After a moment, WindowViewer opens.


6. On the WindowViewer Special menu, select Tag Viewer.

After a moment Tag Viewer opens.


7. Maximize the Tag Viewer window.

InTouch HMI 2017 Update 3


3-60 Module 3 – InTouch Tagname Dictionary

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.

The Rename Tab dialog box appears.


11. In the New Tab Name field, enter Mixer100.

12. Click OK.

InTouch HMI 2017 Update 3


3-62 Module 3 – InTouch Tagname Dictionary

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.

A separator line appears below the tags.

Wonderware Training
Lab 6 – Watching Tags with Tag Viewer 3-63

15. In the tag list, select Mixer100_Pump1_PV.

16. On the toolbar, click the Add to Watch List button.

The Mixer100_Pump1_PV tag appears in the watch list.


17. In the tag list, right-click Mixer100_Pump2_PV, and select Add to Watch.

The Mixer100_Pump2_PV tag appears in the watch list.

InTouch HMI 2017 Update 3


3-64 Module 3 – InTouch Tagname Dictionary

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

Test the Health of the I/O Tags


Next, you will verify the timestamp and quality of the data coming from the PLC Simulator. Your
times and dates will vary.
20. In the watch list Timestamp column, verify that every I/O tag has a timestamp.
21. In the Quality column, verify that every tag has a quality of 192.

A quality of 192 represents good data.


22. In the Mixer100_Temperature_PV row, verify that the timestamp is updating once per
second.
The timestamp is updating once per second because the Update Interval for Topic1 is set to
1000 ms in the OI Server configuration.

InTouch HMI 2017 Update 3


3-66 Module 3 – InTouch Tagname Dictionary

Add a Watch Window


Next, you will add a watch window to the watch list. Additional watch windows allow you to view
different sets of tags in separate tabs.
23. In the empty space of the watch list, right-click and select Add Watch Window.

24. Rename the new tab to Memory Tags.

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

Modify a Tag Value


Next, you will modify the value of a tag. Tag Viewer gives you the ability to write to tags defined as
Read Write. Memory tags cannot be configured as Read Only tags; therefore, you can write to all
memory tags. Tag_Real is defined as a Memory Real tag which allows you to write to its value.
27. In the watch list, double-click Tag_Real.
The Modify Real Value dialog box appears.
28. In the Value field, enter 50.

29. Click OK.


30. In the watch list, verify that the value of Tag_Real displays 50.

InTouch HMI 2017 Update 3


3-68 Module 3 – InTouch Tagname Dictionary

Save a Watch List


Finally, you will save the watch list so that you can access it at a later time.
31. In the empty space of the watch list, right-click and select Save Watch List.

32. In the Save As dialog box, navigate to C:\Training.


33. In the File name field, enter My Watch List.

34. Click Save.


35. Close Tag Viewer.

Wonderware Training
Section 4 – DBDump and DBLoad 3-69

Section 4 – DBDump and DBLoad


This section will explain how to use the DBDump and DBLoad utilities for bulk handling of
InTouch tags.

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.

Backing Up and Restoring the Tagname Dictionary


InTouch has two utility programs to back up and restore your Tagname Dictionary:

DBDump Exports an InTouch application Tagname Dictionary as a .csv (comma-separated


value) file that can be viewed or edited in any program supporting .csv files.
Microsoft Excel is used in this course.
DBLoad Imports an InTouch application Tagname Dictionary as a .csv (comma-separated
value) file that can be viewed or edited in any program supporting .csv files.
Microsoft Excel is used in this course.

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

InTouch HMI 2017 Update 3


3-70 Module 3 – InTouch Tagname Dictionary

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

Key Words Used by DBDump and DBLoad


The .csv file contains a set of keywords that organizes mode commands, Access names, alarm
groups, and tag data within the file.
 A colon (:) precedes all keywords
 To continue a line, enter a backslash (\) at the end of the line
 To enter comments, precede them with a semi-colon (;)
The following table lists the keywords used in the .csv import file. The order of the list is organized
by the DBDump utility. However, you can change the order within the file. The file does not include
all keywords. For example, the .csv file can be as short as 3 lines: a mode line, a tag type header,
and a single tag using that tag type.

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, …

Database Input File Format


The first line of a database input file specifies the operating :mode for the file when it is loaded or
merged into an application using the DBLoad utility. There must always be a mode command on
the first line. However, additional mode commands can be added throughout the file to instruct
DBLoad on how to handle the tags that follow that mode command.
This course uses Microsoft Excel, which interprets the commas in the .csv file as delimiters and
automatically separates the data records into columns and rows.

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.

InTouch HMI 2017 Update 3


3-72 Module 3 – InTouch Tagname Dictionary

Database Input File Operating Modes


The following lists the valid operating mode keywords and the actions that occur in each mode
when a duplicate tagname is encountered during the load:
:mode=ask Change the tagname of the input or the existing entry to your specified
tagname and then insert the new definition into the Tagname Dictionary.
:mode=replace Delete the existing entry and replace it with the new entry.
:mode=update Overwrite the existing definition with only the fields that are explicitly
defined in the input file; i.e., include DELTA changes only.

Note: Additional :mode= options are in the InTouch User Guide.

Wonderware Training
Lab 7 – Exporting and Importing Tags 3-73

Lab 7 – Exporting and Importing Tags

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

InTouch HMI 2017 Update 3


3-74 Module 3 – InTouch Tagname Dictionary

Export the Tags Using DB Dump


In the following steps, you will use the DBDump utility to export Mixer tags to a .csv file.
1. Close WindowViewer.
2. Close WindowMaker.
3. Open the InTouch Application Manager.

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

6. In the Name of CSV Dump file field, enter Mixer100.CSV.

7. Click OK.
A Dump successful message appears.

8. Click OK.

InTouch HMI 2017 Update 3


3-76 Module 3 – InTouch Tagname Dictionary

Modify the Tags


Next, you will open and modify the .csv file in Microsoft Excel. In the spreadsheet, you will change
all Mixer100 tags to Mixer200 to create another set of tags.
9. Open Windows Explorer and navigate to C:\Training.
10. Double-click the Mixer100 file to open it in Microsoft Excel.
11. In Microsoft Excel use Save As to save your file as C:\Training\Mixer200.

Note: Before the next step, ensure that .csv (Comma delimited) is in the Save as type
field.

12. Click Save.


A confirmation message appears.
13. Click Yes to keep the current formatting.

14. In cell A1, replace ask with replace.

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.

17. Click Replace All.

Wonderware Training
Lab 7 – Exporting and Importing Tags 3-77

A confirmation message appears displaying that 18 replacements were made.

18. Click OK.


19. In the Find and Replace dialog box, click Close.
20. In Microsoft Excel, click Save.
21. Click Yes to the confirmation message to keep the current formatting.
22. Close Microsoft Excel.
A confirmation message appears.
23. Click Don’t Save, since you have already saved the file.

24. Close Windows Explorer.

InTouch HMI 2017 Update 3


3-78 Module 3 – InTouch Tagname Dictionary

Import New Tags Using DB Load


Next, you will use the DBLoad utility to import the new .csv file you created. This creates a set of
Mixer200 tags in addition to the Mixer100 tags that were already in the Tagname Dictionary.
25. Open InTouch Application Manager.

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.

27. Click Yes.

The CSV File to Load From dialog box appears.

Wonderware Training
Lab 7 – Exporting and Importing Tags 3-79

28. In the Directories list, double-click [..].


29. In the Files list, select Mixer200.csv.

30. Click OK.


A Load successful message appears.

31. Click OK.

InTouch HMI 2017 Update 3


3-80 Module 3 – InTouch Tagname Dictionary

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

39. Add a watch window named Mixer200.


40. Add all of the Mixer200 tags to the Mixer200 watch window.
41. Verify that all of the Mixer200 tags have a Quality of 192.

42. In the watch list right-click in the empty space and select Save Watch List.

43. Close Tag Viewer.


44. Close WindowViewer.
45. Close WindowMaker.

InTouch HMI 2017 Update 3


3-82 Module 3 – InTouch Tagname Dictionary

Import the Remaining Tags


Finally, to save time creating all of the remaining mixer tags, you will import these from a .csv file
that contains all of the I/O tags necessary to complete the remaining labs. You will then verify that
all of the tags have been imported.
46. Open the InTouch Application Manager.

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.

50. Click OK.


51. In the Database Load message, click OK.
52. Open InTouch Application Manager, and then double-click InTouch Training Application.
53. In the WindowMaker Windows to Open dialog box, select the following windows:
 Current Alarms
 KPI
 Menu
 Mixer

54. Click OK.

Wonderware Training
Lab 7 – Exporting and Importing Tags 3-83

55. On the Special menu, click Tagname Dictionary.


56. Click Select.

The Select Tag dialog box appears.


57. Verify that the Tagname Dictionary has 123 or more tags.

58. Click Cancel.


59. Close the Tagname Dictionary.

InTouch HMI 2017 Update 3


3-84 Module 3 – InTouch Tagname Dictionary

Wonderware Training
Section 5 – Other Tag Management Utilities 3-85

Section 5 – Other Tag Management Utilities


This section will discuss the Cross Reference Utility and Tag use counts. It will explain how to find
and delete tags.

InTouch Cross Reference Utility


The InTouch Cross Reference Utility allows you to determine tagname usage in animation links,
InTouch QuickScript, QuickFunctions, ActiveX controls, ArchestrA graphics, and scripts.
For all animation links, wizards, and ActiveX controls, cross-reference displays the window name
and the coordinates where the tag can be found. It also allows you to view the content of the
QuickScript or QuickFunction where the tag is found.

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.

InTouch HMI 2017 Update 3


3-86 Module 3 – InTouch Tagname Dictionary

Filter and Sort in the Cross Reference Utility


Columns such as Name, Type, and Use may be dragged to the top of cross reference to
automatically sort the contents by those column names. Each subsequent drag operation sub-
sorts the previous column automatically. In each column, a filter button can be used to refine the
search. This includes a custom option for non-default filter criteria.

Use Counts and Unused Tagnames


InTouch maintains a use count for each tagname in the database. This count is not updated
automatically for certain operations, such as deleting a window, changing, or deleting tagnames in
links or scripts. In these cases, InTouch continues to consider the tagname as being used in the
application and does not allow it to be deleted. Therefore, you need to update use counts to
enable deletion of tagnames.

Updating Use Counts


Since InTouch maintains a use count for each tagname in the database, you will need to remove
all references to that tag before you will be allowed to delete it.

Wonderware Training
Section 5 – Other Tag Management Utilities 3-87

Display Tag Count


It is possible to continuously display and update the number of tags used in WindowMaker by
enabling the WindowMaker configuration.

The tag count is displayed in the menu bar of WindowMaker.

InTouch HMI 2017 Update 3


3-88 Module 3 – InTouch Tagname Dictionary

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

Bulk Tag Deletion


After you have updated the use count, the Delete Unused Tags utility will show all tags which can
be deleted.

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

Section 1 – ArchestrA Symbols and Situational Awareness


Visualization
This section will explain the capabilities and usage of the Situational Awareness Library.

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.

ArchestrA Graphic Toolbox


The ArchestrA Graphic Toolbox is a library that stores graphic symbols. In the ArchestrA Graphic
Toolbox, you can create a folder hierarchy to organize symbols. You can also move symbols
around within the folder hierarchy. These folders are named “graphic toolsets”.
The power of ArchestrA graphic symbols is reusability. You can design symbols that can be reused
over and over again with your InTouch application. For example, use the ArchestrA Graphic
Toolbox to create a process graphic that represents a single tank in a tank farm, then re-use the
graphic for every tank in the farm.
When you create a new symbol, it is listed in the ArchestrA Graphic Toolbox. After you create a
symbol, you can move it, or open the ArchestrA Symbol Editor to edit it.

InTouch HMI 2017 Update 3


4-4 Module 4 – Situational Awareness Visualization

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.

Situational Awareness Philosophy


The ArchestrA Graphic Toolbox contains a library of Situational Awareness graphics that have
been created to represent new industry standard graphics. These graphics address the need to
have the operator ascertain the current situation and make key decisions rapidly.
Most HMIs use animation and color to represent plant processes in a very visual manner. Studies
have shown that this has led to a number of cases where the HMI is to blame for slow operator

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

InTouch HMI 2017 Update 3


4-6 Module 4 – Situational Awareness Visualization

The Situational Awareness Library


The ArchestrA Symbol Editor includes a set of Situation Awareness Library symbols. These
symbols include multiple visual and functional configurations that are enabled by selecting values
from a set of wizard options associated with each symbol.
Situation Awareness Library symbols use a largely monochrome color palette, however, it is not
limited to gray-scale only. This is done to increase the contrast between normal operating
conditions and a vivid colored alarm state.
Situation Awareness Library symbols include an extensive set of default custom properties. These
custom properties can be set to show or hide parts of the symbol itself, set the full array of alarm
conditions, and show reported values based on the symbol's configuration.

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.

Situational Awareness Library Wizard Options


When you place a Situational Awareness symbol on a window, and open it for configuration, you
are presented with a list of wizard choices and options. The wizard selections that are made will
effect the look, behavior, size, and position of the graphic on the window. Therefore, after
embedding a Situational Awareness Library symbol on a window, the very first steps are to answer
the wizard choices and options, and then to complete the rest of the configuration such as
placement on the window, labels, and linking to tags.
When you first start out with a brand new Situational Awareness graphic, its physical size in
storage media is very large. As you make choices and select options in the wizard list, the size of
the symbol gets smaller based on the selections made in the wizard options. Any elements,
custom properties, and named scripts not enabled through wizard selections are not included in
the final design. This makes the final symbol light-weight and higher performance.

Wonderware Training
Section 1 – ArchestrA Symbols and Situational Awareness Visualization 4-7

About Custom Properties


You can configure and use custom properties to extend the functionality of symbols and use them
in combination with InTouch tags. You can use binding with custom properties to dynamically
change the reference of a custom property.

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.

InTouch HMI 2017 Update 3


4-8 Module 4 – Situational Awareness Visualization

Wonderware Training
Section 2 – Element Styles 4-9

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.

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.

Application Style Library


A Modern InTouch application can change element styles using the Application Style Library. The
Application Style Library provides an Element Styles tab where the overrides for text, fill, line, and
outline can be modified for each element style. The entire Application Style Library can be
exported or imported.
A set of element styles is provided in the predefined Application Style Library. The Application
Style Library includes a set of 25 user-defined element styles for flexibility and customization.
User-defined element styles appear towards the bottom of the list of the element style overrides
field and are named User_Defined_01 to User_Defined_25. All visual properties of user-defined
Element styles are initially set to default values. Existing element styles cannot be renamed or
deleted. Also, new element styles cannot be added.

Export and Import Application Style Library


The Application Style Library can be exported as an .xml file from WindowMaker. The Application
Style Library can also be imported to override the element styles throughout the application. A pre-
built list of element style libraries has been provide for Modern InTouch applications. For example,
color overrides such as olive, denim, brick, sand, and flora can be selected. This provides
additional to the monochromatic environment.

InTouch HMI 2017 Update 3


4-10 Module 4 – Situational Awareness Visualization

Wonderware Training
Lab 8 – Building a Dashboard 4-11

Lab 8 – Building a Dashboard

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

InTouch HMI 2017 Update 3


4-12 Module 4 – Situational Awareness Visualization

Embed and Configure Situational Awareness Dashboard Symbols


In the following steps, you will embed two Situational Awareness dashboard symbols in the KPI
window.
1. In the WindowMaker ArchestrA Graphic Toolbox, expand InTouch Training
Application\Situational Awareness Library\Dashboard Tools, and select
SA_ColumnChart_Pairs.

Wonderware Training
Lab 8 – Building a Dashboard 4-13

2. Drag SA_ColumnChart_Pairs to the top of the KPI window.

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.

InTouch HMI 2017 Update 3


4-14 Module 4 – Situational Awareness Visualization

3. In the KPI window, right-click SA_ColumnChart_Pairs and select ArchestrA Graphic


“SA_ColumnChartPairs1” | Edit Symbol Properties.

Wonderware Training
Lab 8 – Building a Dashboard 4-15

The Edit Symbol Properties dialog box appears.


4. In the Wizard Options pane, ensure the NumberofBars Wizard Option is selected.
5. On the NumberofBars details pane, Value drop-down list, select Four.
In the background, the symbol on the KPI window represents a preview of the changes made
in Wizard Options. In this example, the 10 bar chart has been updated to show only four bars.

6. In the Wizard Options pane, select ShowAxisDescriptions.


7. On the ShowAxisDescriptions details pane, Value drop-down list, select False.

InTouch HMI 2017 Update 3


4-16 Module 4 – Situational Awareness Visualization

8. Click the Custom Properties tab.


The Bar01A custom property displays details on the right.

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

The Select Tag dialog box appears.


11. Scroll down, and select Mixer100_Totalizer1_PV.

12. Click OK to select the tag and close the Select Tag dialog box.
The tagname is displayed in the Default Value field.

InTouch HMI 2017 Update 3


4-18 Module 4 – Situational Awareness Visualization

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.

14. Click OK.

Wonderware Training
Lab 8 – Building a Dashboard 4-19

15. Right-click the SA_ColumnChart_Pairs symbol, and select Substitute | Substitute Strings.

InTouch HMI 2017 Update 3


4-20 Module 4 – Situational Awareness Visualization

16. Configure the Substitute Strings dialog box as follows:


Current String New String
#.## #.##
0.00 0.00
B1 M100
B2 M200
B3 M300
B4 M400
Chart Heading Consumed Ingredients
Legend A Special Sauce
Legend B Water
Short Description Per Mixer

17. Click OK.

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.

InTouch HMI 2017 Update 3


4-22 Module 4 – Situational Awareness Visualization

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.

InTouch HMI 2017 Update 3


4-24 Module 4 – Situational Awareness Visualization

26. Configure additional custom properties as follows:

Name Default Value


AlarmSeverity 2
AlarmShelved False
BadMax: 7000
GoodMin: 3500
Maximum: 7500
Minimum 0.0
Target: 6500

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.

27. Click OK.

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

30. Click OK.

InTouch HMI 2017 Update 3


4-26 Module 4 – Situational Awareness Visualization

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.

InTouch HMI 2017 Update 3


4-28 Module 4 – Situational Awareness Visualization

Use Element Style Overrides


Next, you will configure the style for the current value of the bullet graph.
33. Click Development!.
34. Close WindowViewer.
35. On the WindowMaker Special menu, select Configure | Application Style Library.

Wonderware Training
Lab 8 – Building a Dashboard 4-29

The Configure Application Styles dialog box appears.

36. Click the Element Styles tab.


37. In the Element Style Overrides list, scroll down and select Actual_Value_Moving_Element.

InTouch HMI 2017 Update 3


4-30 Module 4 – Situational Awareness Visualization

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

The Select Fill Color dialog box appears.


40. On the Solid Color tab, in the Standard Palette area, click a light blue color.

41. Click OK to close the Select Fill Color dialog box.


The Fill Color Override is set to light blue.
42. Click OK to close the Configure Application Styles dialog box.

InTouch HMI 2017 Update 3


4-32 Module 4 – Situational Awareness Visualization

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.

45. Click Development!.

Wonderware Training
Lab 8 – Building a Dashboard 4-33

Import a Galaxy Style Library


Next, you will import a color style using the Application Style Library.
46. Close WindowViewer.
47. On the WindowMaker File menu, select Import | Application Style Library.

48. Navigate to C:\Program Files (x86)\ArchestrA\Framework\Bin\AdditionalElementStyles.


49. Select the file named ElementStyle-Denim.

InTouch HMI 2017 Update 3


4-34 Module 4 – Situational Awareness Visualization

50. Click Open.


A dialog box with an Imported Application Style Library successfully message appears.

51. Click OK.


The graphics in WindowMaker are still gray in color until windows are closed and reopened.

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.

54. Click Development!.

Wonderware Training
Lab 8 – Building a Dashboard 4-35

Convert to ArchestrA Symbol


Finally, you will convert the KPI window to an ArchestrA symbol using the Convert to ArchestrA
Symbol feature.This feature converts all of the graphics on a window, including both legacy
graphics and ArchestrA symbols, into a single ArchestrA symbol. The new symbol is added to the
ArchestrA Graphic Toolbox.
55. On the File menu, select Close Window.

The Windows to Close dialog box opens.


56. Click Select All.

57. Click OK.


All windows are closed.

InTouch HMI 2017 Update 3


4-36 Module 4 – Situational Awareness Visualization

58. In the Windows & Scripts pane, right-click the KPI window, and select Convert to ArchestrA
Symbol.

The Windows to Convert dialog box appears with KPI selected.

59. Click OK.

Wonderware Training
Lab 8 – Building a Dashboard 4-37

The Converting Windows to Symbols dialog box appears and begins converting the
symbol.

When complete, the Window Conversion Report option appears.

60. Click View Details.

The window was converted successfully.

InTouch HMI 2017 Update 3


4-38 Module 4 – Situational Awareness Visualization

61. Click the Window Conversion Report link.


The Window Conversion Report Dialog appears.

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.

65. Collapse the intouch training application toolset.

InTouch HMI 2017 Update 3


4-40 Module 4 – Situational Awareness Visualization

66. Open the KPI window.

67. In the KPI window, click on the graphic.

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.

A WindowMaker confirmation dialog box appears.

69. Click Yes.


70. Open the Menu, Mixer, and Current Alarms windows.

InTouch HMI 2017 Update 3


4-42 Module 4 – Situational Awareness Visualization

Wonderware Training
Section 3 – Window Construction Using Symbol Editor 4-43

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.

Working with Symbols in the ArchestrA Graphic Toolbox


When you create a new symbol using the ArchestrA Graphic Toolbox, it appears in the list. You
can then open the symbol for editing in the ArchestrA Symbol Editor using one of the following
methods:
 Double-click the symbol in the ArchestrA Graphic Toolbox
 Right-click the symbol and select Open
 Select the symbol and click Enter
It is important to note that any changes to the parent ArchestrA symbol are propagated to all
embedded instances of that symbol. The Symbol Editor is an extension of WindowMaker. More
than one Symbol Editor window can be open at a time. However, all Symbol Editor windows must
be close before closing WindowMaker. To see the latest changes in WindowMaker after saving or
closing a symbol in Symbol Editor, one of the following methods must be used to update the
graphic:
 Close and reopen the window
 Switch to runtime to obtain the latest revisions
 Click the Symbol Changed icon at the bottom of the window

Duplicating a Symbol in the ArchestrA Graphic Toolbox


To create duplicate symbols in the ArchestrA Graphic Toolbox use the right-click context menu. A
duplicated symbol is an exact copy of the original symbol but cannot have a duplicate name. No
two symbols can have the same name in the ArchestrA Graphic Toolbox.

Deleting a Symbol in the ArchestrA Graphic Toolbox


You can delete a symbol you no longer need. Deleting a symbol removes it from the ArchestrA
Symbol Library. If you accidentally delete an original library symbol this can be recovered by
importing a file containing all original ArchestrA library objects.
When you delete a symbol, you are shown where the symbol is used. This lets you understand the
impact of deleting the symbol before you actually delete it. If you delete a symbol that is used in an
InTouch window, it is not deleted from that window. However, the ArchestrA animation links no
longer work and you cannot edit the symbol with the Symbol Editor

InTouch HMI 2017 Update 3


4-44 Module 4 – Situational Awareness Visualization

Export Selected Symbols from the ArchestrA Toolbox in Modern


Applications
Instead of exporting or importing the entire set of ArchestrA symbols, one or more selected
symbols can be exported or imported. The selected ArchestrA symbols are exported to an .aaPKG
file to a designated folder location. If you export a symbol with other symbols embedded, all of the
symbols are exported when the host symbol is exported.

Accessing Help on ArchestrA Symbols


Extensive HTML documentation is available on the Situational Awareness Library. This can be
accessed from the context menu in the ArchestrA Graphics Toolbox. Opening the Help
documentation for the first time requires providing permission in the default web browser in your
environment.

ArchestrA Symbol Editor


The ArchestrA Symbol Editor is comprised of the following components:

Tools Pane
The Tools pane contains elements you can use to draw on the canvas.

The Tools pane contains the following components:


 A pointer tool to select and move elements on the canvas
 Basic geometrical objects, such as lines, rectangles, polygons, and arcs
 A status element you can use to show the quality and status of selected ArchestrA
attributes
 Windows common controls, such as combo boxes, calendar controls, and radio button
groups

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

InTouch HMI 2017 Update 3


4-46 Module 4 – Situational Awareness Visualization

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.

Editing Element Properties


You can control the appearance of an element, a group of elements, or multiple elements with
functions on the toolbar and properties in the Properties pane.
Often you can edit an element by changing the values of its properties instead of using the mouse
to perform the same function. This is useful when you want very exact editing, such as when you
want to resize an element to a specific width.

Selecting Tags and Dotfields within ArchestrA Symbol Editor


InTouch Tags and dotfields may be selected in the Symbol Editor. From the InTouch Tag Browser
tab within the Galaxy Browser the DotFields selector may be used to select a dotfields. The syntax
for InTouch tags and dotfields in the Symbol editor is prefixed by InTouch:. For example
InTouch:Analog003.MaxEU.
InTouch tags are selected in Symbol Editor to select a default value for custom properties marked
with Public Visibility. These default values can then be overridden in WindowMaker. The exception
to this is when a symbol has been placed into a Frame window. Frame windows require that all
tags are linked in the Symbol Editor before the symbol is embedded.

Placeholders versus Hard-Coded Links in Custom Properties


Fixed tag links in the Symbol Editor represents the default value that the custom property will use
in both WindowMaker and WindowViewer. In some cases, rather than hard-code an actual
InTouch tagname, the use of a placeholder, which is represented by three contiguous dash
characters (---) is used to make the symbol generic in the library. In such cases where a
placeholder is used the symbol will not work directly after embedding it into a window.
If this method is used, an additional step of linking tags to replace the placeholders is necessary.
This prevents accidentally using a symbol in runtime linked to the wrong data source because
there is a visual notation that appears in runtime that indicates something has not been configured
properly. This forces the step of linking tags before using the symbol.
Search and replace features do not work with placeholders. The design decision to hard-code tags
instead of using placeholders allows the Substitute References feature to be used to replace all
references in the symbol quickly to link to new data sources.

InTouch HMI 2017 Update 3


4-48 Module 4 – Situational Awareness Visualization

Selecting Dotfields within the Select Tag Dialog Box


Dotfields may be used as the data source for a custom property in ArchestrA graphics. The
selected dotfield must match the correct data type expected for the custom property. Linking
dotfield properties of tags, such as .EngUnits and .MaxEU, to custom properties is done by
selecting them from the dotfield drop-down list within the Select Tag dialog box in WindowMaker.
When using the Symbol Editor, this same selection can be done using the Galaxy browser.

Selecting dotfields within Native InTouch Animations and Expressions


In native InTouch Animation expressions and scripts you can popup a quick pick list of dotfields
using a shortcut. After entering a tagname followed by a dot (.) double-click to the right of the dot,
and a popup window containing the InTouch dotfields list will appear. This is a complete list of all
dotfields, some of which may be invalid for the tagname that is used in the expression. Consult the
Help documentation for a detailed understanding of every dotfield.

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.

Selecting Appropriate Tags and DotFields for Custom Properties


When choosing a tag or dotfield, the data type must match the appropriate data type in the symbol
or animation that it is used. The icon associated with the tag represents its data type, even if you
are unfamiliar with the tags definition. The tag selected must be aligned with the data type of the
custom property. Dotfields, on the other hand, may be different data type than the tag that the tag
that they are associated with. If a dotfield is used, the dotfield data type overrides the tag data type
for the purpose of linking to a custom property.
When working with InTouch message tags or string data there is a toggle button next to the
Default Value field of a string custom property. This switch, used only with String data types,
allows you to chose between linking a message tag or a string type dotfield. The mode that
supports referencing a tag or dotfield is referred to as Reference or Expression mode. This mode
supports both mathematical and logical expressions. For example, the following logical expression
can be used with this mode enabled Mixer100_Inlet1_OLS and not Mixer100_Inlet1_CLS. The
second mode of this toggle button is referred to as Static Text mode. In Static Text mode you are
allowed to enter any string or text. This entry will not be referenced (looked up) or calculated.

InTouch HMI 2017 Update 3


4-50 Module 4 – Situational Awareness Visualization

Wonderware Training
Lab 9 – Building the Mixer Operational Display 4-51

Lab 9 – Building the Mixer Operational


Display

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

InTouch HMI 2017 Update 3


4-52 Module 4 – Situational Awareness Visualization

Create the Mixer Symbol


In the following steps, you will create a new symbol named Mixer, which you will build using
Situational Awareness Library symbols.
1. In the WindowMaker ArchestrA Graphic Toolbox, collapse the Situational Awareness
Library.

2. Right-click the top most InTouch Training Application node, and select New | Graphic
Toolset.

3. Name the toolset Training.

4. Right-click Training, and select New | Symbol.

Wonderware Training
Lab 9 – Building the Mixer Operational Display 4-53

The new symbol appears in the ArchestrA Graphic Toolbox.

5. Rename the symbol Mixer.

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.

7. Maximize the ArchestrA Symbol Editor.

InTouch HMI 2017 Update 3


4-54 Module 4 – Situational Awareness Visualization

8. On the toolbar, click the Embed Graphic button.

The Galaxy Browser appears.


9. In the Graphic Toolbox pane, expand Situational Awareness Library, and click the
Equipment toolset.

Wonderware Training
Lab 9 – Building the Mixer Operational Display 4-55

10. In the Equipment pane, scroll down, and select SA_Valve_2Way.

11. Click OK.

On the canvas, the cursor changes to an angle bracket .


12. On the top-left corner of the canvas, click to place the symbol.

InTouch HMI 2017 Update 3


4-56 Module 4 – Situational Awareness Visualization

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.

InTouch HMI 2017 Update 3


4-58 Module 4 – Situational Awareness Visualization

The Substitute Strings dialog box appears.


16. In the Substitute Strings dialog box, enter Inlet 1.

17. Click OK.


The label on the symbol is updated.

Wonderware Training
Lab 9 – Building the Mixer Operational Display 4-59

18. Right-click the Inlet1 symbol, and select Custom Properties.

The Edit Custom Properties dialog box appears.


Next, you will select tags and create an expression for the Default Value field.
19. In the Custom Properties pane, verify that EquipStateActive is selected.

InTouch HMI 2017 Update 3


4-60 Module 4 – Situational Awareness Visualization

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.

22. Click the InTouch Tag Browser tab.

InTouch HMI 2017 Update 3


4-62 Module 4 – Situational Awareness Visualization

23. In the tag list, scroll down, and select Mixer100_Inlet1_OLS.

24. Click OK.


The Default Value field displays the fully qualified reference to the InTouch tag which includes
the prefix InTouch:.

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.

29. Click OK.

InTouch HMI 2017 Update 3


4-64 Module 4 – Situational Awareness Visualization

The final expression will look like the following image.

30. In the Custom Properties pane, select EquipStateActual.

Wonderware Training
Lab 9 – Building the Mixer Operational Display 4-65

31. In the EquipStateActual details pane, Visibility option, select Private.

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.

InTouch HMI 2017 Update 3


4-66 Module 4 – Situational Awareness Visualization

34. In the PV details pane, Default Value field, delete Me.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.

38. Double-click the Default Value field, and select Mixer100_Inlet1_Position.


39. In the DotFields list, select MaxEU.
The tagname and dotfield are displayed in the status bar of the Galaxy Browser.

40. Click OK.


InTouch:Mixer100_Inlet1_Position.MaxEU appears in the Default Value field.
41. In the Custom Properties pane, select PVMin, and delete the Default Value.
42. Double-click the Default Value field, and select Mixer100_Inlet1_Position.
43. In the DotFields list, select MinEU, and click OK.

InTouch HMI 2017 Update 3


4-68 Module 4 – Situational Awareness Visualization

The Custom Properties pane will look like the following image.

44. Click OK.

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

A duplicate valve appears.

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.

InTouch HMI 2017 Update 3


4-70 Module 4 – Situational Awareness Visualization

50. Right-click the Inlet2 valve, and select Substitute | Substitute References.

The Substitute References dialog box appears.


51. Click Find & Replace.

Wonderware Training
Lab 9 – Building the Mixer Operational Display 4-71

The Find & Replace pane appears.

52. In the Find What field, enter Inlet1.


53. In the Replace with field, enter Inlet2.

54. Click Replace All.

InTouch HMI 2017 Update 3


4-72 Module 4 – Situational Awareness Visualization

The Replace All button replaces all references of Inlet1 with Inlet2.

55. Click OK.


Next, you will create a third valve named Outlet.
56. Repeat the previous steps to duplicate the Inlet2 valve, and configure the duplicate symbol as
follows:

Properties Name field: Outlet


Substitute Strings: Outlet
Substitute References: Outlet

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.

57. Click the Embed Graphic button.


58. In the Galaxy Browser, click the SA_Pump_Blower_RotaryValve symbol.

59. Click OK.


60. Place the symbol to the right of Inlet1.

InTouch HMI 2017 Update 3


4-74 Module 4 – Situational Awareness Visualization

61. Name the symbol Pump1.


62. Label the symbol Pump 1.

63. Right-click the Pump1 symbol, and select Custom Properties.


64. Configure the custom properties as follows:
Custom Property Default Value Visibility
EquipState InTouch:Mixer100_Pump1_PV Public
LabelVisible True Public

The Edit Custom Properties dialog box will look like the following image.

65. Click OK.


Next, you will create a duplicate pump.
66. Duplicate Pump1, and place the duplicate to the right of Inlet2.

Wonderware Training
Lab 9 – Building the Mixer Operational Display 4-75

67. Configure the duplicate symbol as follows:

Properties Name field: Pump2


Substitute Strings: Pump 2
Substitute References: Pump2

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.

68. Click the Embed Graphic button.


69. In the Galaxy Browser, click the SA_Agitator_Settler symbol.

70. Click OK.

InTouch HMI 2017 Update 3


4-76 Module 4 – Situational Awareness Visualization

71. Place the Agitator symbol to the right of Pump1 and Pump2.
72. Name the symbol Agitator.
73. Change the label to Agitator.

74. Configure the custom properties as follows:


Custom Property Default Value Visibility
EquipState InTouch:Mixer100_Agitator_PV Public
LabelVisible True Public
PV EquipState * 100 Private
PVRangeFullScaleMax 100 Private
PVRangeFullScaleMin 0 Private

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%.

75. Click OK.

Wonderware Training
Lab 9 – Building the Mixer Operational Display 4-77

Next, you will add a level meter to the Mixer symbol.

76. Click the Embed Graphic button.


77. In the Galaxy Browser Graphic Toolbox pane, click the Meters toolset.
78. In the Meters pane, select the SA_Meters symbol.

79. Click OK.


80. Place the SA_Meters symbol to the right of Agitator.

InTouch HMI 2017 Update 3


4-78 Module 4 – Situational Awareness Visualization

81. Name the symbol Level.


82. On the Wizard Options area, Type drop-down list, select Level.

83. Change the labels as follows:


Old New
EU Gallons
Label Level

Wonderware Training
Lab 9 – Building the Mixer Operational Display 4-79

84. Configure the custom properties as follows:


Custom Property Default Value Visibility
PV InTouch:Mixer100_Level_PV Public
PVRangeFullScaleMax InTouch:Mixer100_Level_PV.MaxEU Public
PVRangeFullScaleMin InTouch:Mixer100_Level_PV.MinEU Public

85. Click OK.


Next, you will duplicate Level and modify it to become a temperature meter.
86. Duplicate Level, and place the duplicate to the right of Level.
87. Name the duplicate Temperature.
88. On the Wizard Options area, Type drop-down list, select Temperature.
89. Configure the duplicate symbol as follows:

Change From To
Substitute Strings: Gallons DegF
Substitute Strings: Level Temperature
Substitute References (Find & Replace): Level Temperature

InTouch HMI 2017 Update 3


4-80 Module 4 – Situational Awareness Visualization

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.

90. Click the Embed Graphic button.


91. In the Galaxy Browser Graphic Toolbox pane, click the Equipment toolset.
92. In the Equipment pane, select the SA_Tank_Vessel symbol.

93. Click OK.


94. Place the SA_Tank_Vessel symbol anywhere on the canvas.
95. Name the symbol Tank.
96. On the Wizard Options area, Type drop-down list, select Tank.
97. On the Size drop-down list, select Large.

Wonderware Training
Lab 9 – Building the Mixer Operational Display 4-81

98. On the LabelType drop-down list, select CustomPropertyLabel.

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.

InTouch HMI 2017 Update 3


4-82 Module 4 – Situational Awareness Visualization

102.In the Default Value field, enter Mixer100.

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

Add Pipes to the Mixer


Next, you will add Connectors and Connection Points to represent piping.
105.On the top toolbar of the symbol editor, click the Canvas Zoom drop-down list, and select Fit.

106.Click Snap to Grid to turn off the snap to grid feature.

107.In the Tools pane, double-click Connection Point.


Double-clicking a tool saves time by not requiring you to reselect the tool when using it
multiple times. Clicking another tool or pressing the Esc key will cancel the operation.

InTouch HMI 2017 Update 3


4-84 Module 4 – Situational Awareness Visualization

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.

109.Click to place the Connection Point.

110.Add a Connection Point to the Tank across from Pump2.


111.In the Tools pane, select Connector.

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.

113.In the Tools pane, select Connector.


114.Hover over the Connection Point on the right side of Inlet1, and drag the Connector to the
Connection Point in the center of Pump1.

115.In the Elements list, select Connector2, and on the Properties pane, ConnectionType drop-
down list, select Straight.

InTouch HMI 2017 Update 3


4-86 Module 4 – Situational Awareness Visualization

The bends in the Connector are removed.

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.

InTouch HMI 2017 Update 3


4-88 Module 4 – Situational Awareness Visualization

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

Embed the Mixer Symbol in the Mixer Window


Next, you will embed the Mixer symbol in the Mixer window in WindowMaker.
123.In the WindowMaker ArchestrA Graphic Toolbox, Training toolset, click Mixer.
124.Drag the Mixer symbol onto the Mixer window.
The Frame window automatically centers and stretches the symbol to fill the window.

125.On the Properties pane, ShowZoomControl drop-down list, select Visible.

InTouch HMI 2017 Update 3


4-90 Module 4 – Situational Awareness Visualization

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.

Notice the Mixer graphic is larger after zooming.


128.On the ZoomControl toolbar, click the Pan button.

InTouch HMI 2017 Update 3


4-92 Module 4 – Situational Awareness Visualization

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.

Note: You cannot pan a graphic at a zoom of 100.

135.On the ZoomControl toolbar, click the Zoom Normal button.

Observe that the Mixer graphic has been restored to its original size.
136.Click Development!.

InTouch HMI 2017 Update 3


4-94 Module 4 – Situational Awareness Visualization

Wonderware Training
Section 4 – Custom Properties and Animations in Symbols 4-95

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.

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.

InTouch HMI 2017 Update 3


4-96 Module 4 – Situational Awareness Visualization

Custom Properties Dialog Box


The Custom Properties dialog box allows the addition, deletion, and configuration of custom
properties. From this dialog box, you add a custom property, name it, set its data type, default
value, mark it public or private and provide a description.

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

Creating a Custom Property


At this point in the course you have only used existing custom properties to link tags and dotfields.
You can also create your own custom properties for use in a symbol. For this purpose, the Edit
Custom Properties dialog box allows you to add and delete custom properties. When a custom
property is first created, it can be given a name and the data type can be selected. Unlike tags in
InTouch, custom properties do not require setting Min and Max range for values.

Validating Custom Properties


The red check mark at the top right of the Edit Custom Properties dialog box allows you to verify
the syntax, expression, or entry of the Default Value field. The use of the Validate feature is for
cases where you are building a lengthy expression and need to confirm that the formatting and
syntax are correct. Otherwise, this step is optional because clicking OK to save the changes
automatically performs a Validate.

Clearing the Configuration of Custom Properties


Next, to the Validate option in the top right corner of the Edit Custom Properties dialog box is the
eraser button, which clears the content of the Default Value field and restores a default value
appropriate to the selected data type. This ensures no errors will be encountered when providing
the appropriate default value after clearing the contents of the Default Value field.

Renaming Custom Properties


To rename a custom property, first select the custom property name in the Custom Properties list,
pause, and click a second time. An edit field will appear and allow you to rename the custom
property. It should be noted that renaming a custom property will impact animations, expressions,
references, and scripts that referenced the original custom property name.
The following rules will assist in naming custom properties appropriately:
 If the symbol includes an embedded symbol, the name of the custom property cannot be
the same as the name of the embedded symbol or of an element of the embedded symbol
 A script using a dimensioned local variable (to be covered later) cannot match the name of
a custom property
 If an element or a group is renamed, the animation references to it are not automatically
updated. All animation links must be changed manually to reference the old name

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.

InTouch HMI 2017 Update 3


4-98 Module 4 – Situational Awareness Visualization

Visualization and Interaction Animation Types


There are two types of animations:
 Visualization animations determine the appearance of the element, such as visibility,
blinking, fill style, percent fill horizontal, or value display
 Interaction animations determine the behavior of an element, allowing a user to click,
drag, or type to interact with the element. For example a horizontal slider used to change
an analog value
 There are visualization and interaction animations that are specific to certain elements.
For example, the DataStatus animation is specific to the Status element. Element-specific
animations also determine element behavior and appearance.
You can configure the following common animation types:

Animation Type Description


Visibility Shows or hides the element depending on a value or an expression.
Fill Style Specifies the interior fill style depending on a discrete or analog expression or one
or more conditions.
Line Style Specifies the style and pattern of the element line depending on a discrete or analog
expression or one or more conditions.
Text Style Specifies the style of the element text depending on a discrete or analog expression
or one or more conditions.
Blink Sets the element to blink invisibly or with specified colors depending on a discrete
value or expression.
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.
% Fill Horizontal Fills the element with color partially from left to right or vice versa, depending on an
analog value or expression.
% Fill Vertical Fills the element with color partially from top to bottom or vice versa, depending on
an analog value or expression.
Location Horizontal Positions the element with a horizontal offset depending on an analog value or
expression.
Location Vertical Positions the element with a vertical offset depending on an analog value or
expression.
Width Increases or decreases the element width depending on an analog value or
expression.
Height Increases or decreases the element height depending on an analog value or
expression.
Point Changes the X and Y coordinate values of one or more selected points on a symbol
or graphic element.
Orientation Rotates the element by an angle around its center point or any other point
depending on an analog value or expression.
Value Display Shows a discrete, analog, string value, time value, name or expression.
Tooltip Shows a value or expression as a tooltip when the mouse is moved over the
element.
Disable Disables the element’s animation depending on a Boolean value or expression.
User Input Enables the run-time user to type a Boolean, analog, string, time or elapsed time
value that is then assigned to an attribute.
Slider Horizontal Enables the run-time user to drag the element left or right and write back the offset
to an analog attribute.
Slider Vertical Enables the run-time user to drag the element up or down and write back the offset
to an analog attribute.
Pushbutton Writes predetermined values to Boolean or analog references when the user clicks
on the element.
Action Scripts Runs an action script when the run-time user clicks on the element.
Show Symbol Shows a specified symbol at a specified position when the run-time user clicks on
the element.
Hide Symbol Hides a specified symbol when the run-time user clicks on the element.

Wonderware Training
Section 4 – Custom Properties and Animations in Symbols 4-99

Connectors and Connection Points


Connectors allow a visual representation of the association between two elements on the canvas.
For example, Connectors can be used to represent pipes or electrical wiring in an P&ID diagram.
Connectors must be anchored to a Connection Point. After a Connector has been anchored,
the element associated with the Connection Point can be repositioned on the canvas and the
Connector will follow the graphic automatically.
The resize handles of every graphic act as native Connection Points to anchor a Connector.
Using Connection Points, you can add your own custom anchors for a Connector.

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.

InTouch HMI 2017 Update 3


4-100 Module 4 – Situational Awareness Visualization

Wonderware Training
Lab 10 – Building a Command Symbol 4-101

Lab 10 – Building a Command Symbol

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

InTouch HMI 2017 Update 3


4-102 Module 4 – Situational Awareness Visualization

Create a CMD Symbol


In the following steps, you will create a symbol to start and stop the mixer pumps.
1. In WindowMaker, in the ArchestrA Graphic Toolbox, right-click the Training toolset and
select New | Symbol.

2. Name the new symbol CMD.

3. Double-click CMD to open it for editing.


4. In the ArchestrA Symbol Editor, right-click a blank spot on the canvas, and select Custom
Properties.

The Edit Custom Properties dialog box appears.

Wonderware Training
Lab 10 – Building a Command Symbol 4-103

5. In the Edit Custom Properties dialog box, click the Add custom property button.

6. In the Name field, enter CMD.

7. Press Enter to accept the name.


The CMD custom property is added to the Custom Properties pane.

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.

InTouch HMI 2017 Update 3


4-104 Module 4 – Situational Awareness Visualization

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.

12. Click OK to close the Edit Custom Properties dialog box.

Wonderware Training
Lab 10 – Building a Command Symbol 4-105

Add Command Buttons


Next, you will add buttons to the empty canvas and animate them.

13. In the Tools pane, select the Button tool.

14. On the canvas, click and drag down and to the right to draw a button.
15. Enter Start for the button text.

16. Press Enter to accept the name.

InTouch HMI 2017 Update 3


4-106 Module 4 – Situational Awareness Visualization

17. In the Properties pane, name the button Button_Start.


18. In the Properties pane, on the ElementStyle drop-down list, select Intensity1.
19. In the Properties pane, Width field, enter 50.
20. In the Properties pane, Height field, enter 20.

Next, you will add animations to the button.


21. Double-click the button to open the Edit Animations dialog box.
22. In the Edit Animations dialog box, click Add Animation.

Wonderware Training
Lab 10 – Building a Command Symbol 4-107

23. On the Interaction list, select Pushbutton.

The Pushbutton animation details pane appears.


24. In the Pushbutton animation details pane, click Boolean.

InTouch HMI 2017 Update 3


4-108 Module 4 – Situational Awareness Visualization

25. In the Boolean field, enter CMD.


26. In the Action area, click Set.

27. Add an Element Style animation.

Wonderware Training
Lab 10 – Building a Command Symbol 4-109

28. In the Element Style animation details pane, select Boolean.


29. In the Boolean field, enter CMD.
30. In the Values area, True, 1, On field, on the drop-down list, select Intensity4.
31. In the False, 0, Off field, uncheck the Element Style check box.

Note: When an Element Style is disabled, the configured Element Style of the element is
used.

32. Click OK to close the Edit Animations dialog box.

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.

InTouch HMI 2017 Update 3


4-110 Module 4 – Situational Awareness Visualization

34. In the Properties pane, name the button Button_Stop.


35. In the Text field, enter Stop.

36. Double-click the Button_Stop button to edit the animations.


37. Ensure the Element Style animation is selected in the Animations list.
38. In the Element Style animation details pane, in the True, 1, On field, uncheck the Element
Style check box.
39. In the False, 0, Off field, check Element Style and using the drop-down list, select Intensity4.

Wonderware Training
Lab 10 – Building a Command Symbol 4-111

40. In the Animations list, select the Pushbutton animation.


41. In the Pushbutton animation details pane, in the Action area, click Reset.

42. Click OK.


43. In the top left corner of the ArchestrA Symbol Editor, click the Save and Close button.

InTouch HMI 2017 Update 3


4-112 Module 4 – Situational Awareness Visualization

Embed the CMD Symbol in the Mixer Symbol


Next, you will add the CMD symbol to the Mixer symbol two times. You will link pump tags to these
embedded instances.
44. In WindowMaker, ArchestrA Graphic Toolbox, double-click Mixer to open it for editing.

45. Click the Embed Graphic button.


46. In the Galaxy Browser Graphic Toolbox pane, click the Training toolset.
47. In the Training pane, select the CMD symbol.

48. Click OK.


49. Place the CMD symbol below Pump 1 on the canvas.

Wonderware Training
Lab 10 – Building a Command Symbol 4-113

50. Name the symbol Pump1_CMD.

51. Right-click Pump1_CMD and select Custom Properties.


52. In the Custom Properties pane, ensure CMD is selected.

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.

56. Click OK.

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.

InTouch HMI 2017 Update 3


4-114 Module 4 – Situational Awareness Visualization

59. With the duplicate selected, name the symbol Pump2_CMD.

In the Elements list, the name has been updated.

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

Test What You Have Built


Finally, you will open WindowViewer and test the new CMD buttons.
64. Click Runtime.
65. For Pump1_CMD and Pump2_CMD, click Start and then click Stop to operate the pumps.
Notice you can halt the increase of the level if you stop a pump while its associated valve is
active.

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!.

InTouch HMI 2017 Update 3


4-116 Module 4 – Situational Awareness Visualization

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

Section 1 – InTouch Tagname Alarm Configuration

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.

InTouch HMI 2017 Update 3


5-4 Module 5 – InTouch Alarms

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.

Alarm and Event Properties


When an alarm or event is configured for a tag, a priority between 1 and 999 must be provided,
where 1 is the highest priority.
The table below shows a suggested range for critical, major, minor, and informational alarms. This
range might be specified by regulations:

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.

Dotfield Name Description


.Ack Monitors/controls the alarm acknowledgment status of tags and alarm controlling
alarm properties of tags and groups at runtime.
.Ack has an inverse tag dotfield named .UnAck. When an unacknowledged alarm
occurs, .UnAck is set to 1. The .UnAck dotfield can be used in animation links or
condition scripts to trigger annunciators for any unacknowledged alarms.
.Alarm Signals that an alarm condition exists.
.AlarmEnabled Disables/enables events and alarms.
.HiLimit, .HiHiLimit, Read/write analog tagname dotfields that monitors /controls the limits for value
.LoLimit, .LoLoLimit alarm checks. These dotfields are only valid for integer and real tags.

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.

InTouch HMI 2017 Update 3


5-6 Module 5 – InTouch Alarms

Alarm Border Animation


Alarm Border animation shows a highly visible colored border around a graphic element or group
of elements, when an alarm condition occurs. The color and fill pattern of the border indicates the
severity and current state of the alarm. Alarm Border animation enables operators to quickly
recognize alarm conditions.

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

Alarm Border Animation Behavior


Alarm Border animation appears around a graphic element based on the current state of the
object's aggregated alarm attributes. The appearance of the alarm border itself reflects the current
alarm state and the user's interaction with the alarm.
 A symbol process value transition into an alarm state: Alarm Border animation appears
around the symbol based on alarm severity with blinking
 The user acknowledges an alarm with the process value still in an alarm state: Alarm
Border animation appears around the symbol without blinking
 The alarm value returns to normal without the user acknowledging the alarm: Alarm
Border animation remains around the symbol in a defined Return to Normal visual style
without blinking

 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

InTouch HMI 2017 Update 3


5-8 Module 5 – InTouch Alarms

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

Configure Alarm Border Overrides


Alarm border animation shows an indicator icon at the top-left corner of the border with alarm
severity as a number from 1 to 4. A default alarm border indicator image is assigned to each alarm
severity level. The default images appear in the Image column of the Alarm and Event Priority
Mapping and Historization dialog box. This is accessed in WindowMaker, Special | Configure |
Alarm Priority Mappings option. The images are saved in an .xml file located in the ArchestrA
global data cache.

Modify Alarm Border Animation Element Styles


The color and fill pattern of alarm borders are set by the Outline properties of a set of alarm
Element Styles. The following table shows the Element Styles applied to alarm border animations
by alarm severity and alarm state. The assignment of these Element Styles to alarm conditions
cannot be changed. Only the assigned Element Style Outline properties can be changed to modify
the appearance of alarm borders.
Alarm
Alarm State Element Style
Severity
1 UnAcknowledged Alarm_Critical_UNACK
1 Acknowledged Alarm_Critical_ACK
1 Return To Normal Alarm_Critical_RTN
2 UnAcknowledged Alarm_High_UNACK
2 Acknowledged Alarm_High_ACK
2 Return To Normal Alarm_High_RTN
3 UnAcknowledged Alarm_Medium_UNACK
3 Acknowledged Alarm_Medium_ACK
3 Return To Normal Alarm_Medium_RTN
4 UnAcknowledged Alarm_Low_UNACK
4 Acknowledged Alarm_Low_ACK
4 Return To Normal Alarm_Low_RTN
All Suppressed Alarm_Suppressed

InTouch HMI 2017 Update 3


5-10 Module 5 – InTouch Alarms

Alarm Acknowledgment Models


Acknowledged alarms can be processed in a variety of methods, based on the industry regulations
and network environments. InTouch is configured to automatically acknowledge an alarm which
returns to normal. However, regulated industries can disable this feature.
Alarm Acknowledgment models include the following:
 Condition – This is the default state and handles alarms as an instance. That is, only the
most current alarm state is shown and may be acknowledged. For example, a tag
configured with both a Lo and a LoLo state, that is currently in a LoLo alarm implies that it
is also in a Lo alarm as the value must cross through the Lo state in order to reach the
LoLo state. Thus, when the LoLo instance is acknowledged the Lo state is automatically
acknowledged.
 Event Oriented – This alarm state is similar to condition acknowledgment, except it is
designed to deal with race conditions frequently occurring in high latency networks, such
as acknowledgment from an operator station connected over the Internet.
 Expanded Summary – This is the alarm model typically used for regulated industries.
This option requires each state and sub-state be recorded as acknowledged separately.

Wonderware Training
Lab 11 – Configuring InTouch Alarms 5-11

Lab 11 – Configuring InTouch Alarms

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

InTouch HMI 2017 Update 3


5-12 Module 5 – InTouch Alarms

Configure Alarms for Mixer


In the following steps, you will add and configure alarm limits within the mixer temperature tag.
Then, you will add and configure an Alarm Border animation and LimitAlarm marks for the
Temperature element of the Mixer symbol.
1. In the WindowMaker Tagname Dictionary, select the Details and Alarms option.

2. Click the Select button.


3. In the Select Tag dialog box, select Mixer100_Temperature_PV.

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:

Tagname Enable LoLo Limit Enable Hi Limit


Mixer200_Temperature_PV 120 150
Mixer300_Temperature_PV 120 150
Mixer400_Temperature_PV 120 150

9. Click Close to save and close the Tagname Dictionary.

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.

InTouch HMI 2017 Update 3


5-14 Module 5 – InTouch Alarms

12. On the AlarmLimitIndicators drop-down list, select True.


More properties appear.

13. Configure the additional properties as follows:

AlarmHiLimitIndicator: True
AlarmLoLoLimitIndicator: True
AlarmBorder: True

Wonderware Training
Lab 11 – Configuring InTouch Alarms 5-15

14. Right-click Temperature and select Custom Properties.


15. Configure the custom properties as follows:
Custom Property Default Value Visibility
AlarmHiLimit InTouch:Mixer100_Temperature_PV.HiLimit Public
AlarmIndicatorVisible True Private
AlarmLoLoLimit InTouch:Mixer100_Temperature_PV.LoLoLimit Public
AlarmMostUrgentAcked InTouch:Mixer100_Temperature_PV.Ack Public
AlarmMostUrgentInAlarm InTouch:Mixer100_Temperature_PV.Alarm Public
AlarmMostUrgentMode 1 Private
AlarmMostUrgentSeverity 1 Private
AlarmMostUrgentShelved False Private

Note: For tag-based designs, Alarm-Urgency Reference sources (Mode, Severity, and
Shelved) must be set to fixed values.

16. Click OK.


17. Save and close Mixer.

InTouch HMI 2017 Update 3


5-16 Module 5 – InTouch Alarms

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

Configure Alarm Properties


Next, you will configure the Alarm Properties of the application to disable the behavior that causes
the alarm border to hide when the alarm value returns to normal.
21. Close WindowViewer.
22. In the WindowMaker Tools pane, expand Configure, and double-click Alarms.

The Alarm Properties dialog box appears.


23. Uncheck the RTN implies ACK check box.

24. Click OK.

InTouch HMI 2017 Update 3


5-18 Module 5 – InTouch Alarms

Verify the Alarm Border Configuration


Next, you will identify the override pattern that is used when an alarm returns to normal.
25. On the WindowMaker Special menu, select Configure | Application Style Library.

The Configure Application Styles dialog box appears.

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.

27. Click the Outline tab.

InTouch HMI 2017 Update 3


5-20 Module 5 – InTouch Alarms

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.

31. Click Development!.

InTouch HMI 2017 Update 3


5-22 Module 5 – InTouch Alarms

Create an Alarm Group


Next, you will create and configure alarm groups that you will add tags to.
32. Close WindowViewer.
33. Create a new tag and configure it as follows:

Tagname: MixerGroup_Inhibit
Data Type: Memory Discrete

34. In the Tools pane, double-click Alarm Groups.

The Alarm Groups dialog box appears.

Wonderware Training
Lab 11 – Configuring InTouch Alarms 5-23

35. Click the Add button.


The Add Alarm Group dialog box appears.
36. In the Group Name field, enter Mixers.

37. Click OK.


In addition to creating an alarm group named Mixers, InTouch automatically creates a Mixers
tag to represent this group. This new tag is added as a child of the $System master alarm
group.

38. Click Close.


The Mixers group has been added as a Group Var type tag in the Tagname Dictionary.

InTouch HMI 2017 Update 3


5-24 Module 5 – InTouch Alarms

Configure Alarm Inhibit for an Alarm Group


Next, you will link an Alarm Inhibitor tag for the Mixers group.
39. In the Tagname Dictionary, select the Mixers tag, and click OK.

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.

43. Click Save.

InTouch HMI 2017 Update 3


5-26 Module 5 – InTouch Alarms

Add Tags to Alarm Groups


Next, you will assign alarm groups to tags.
44. Select the Mixer100_Temperature_PV tag, and click the Group button.

45. In the Alarm Groups dialog box, select Mixers.


46. Click Close to select the Mixers alarm group.
The Mixers group is selected for the Mixer100_Temperature_PV tag.

Wonderware Training
Lab 11 – Configuring InTouch Alarms 5-27

Configure the Alarm Acknowledgment Model


Next, you will select the Expanded Summary ACK Model for the temperature tags. Expanded
Summary provides a time and date stamp for each alarm state change.
47. In the Alarms pane, ACK Model area, select the Expanded Summary option.

48. Click Save.


49. Repeat the previous steps to select the Mixers group, and Expanded Summary ACK Model
for each of the following tags:
 Mixer200_Temperature_PV
 Mixer300_Temperature_PV
 Mixer400_Temperature_PV

Define an Alarm State for a Discrete Tag


Next, you will configure the alarm for a discrete tag created in an earlier lab.
50. Select Tag_Discrete1, and then in the Alarm State area, select On.

Notice the Group is $System and the ACK Model is set to Condition.
51. Click Close.

Note: As a reminder, the Close button also saves your changes.

InTouch HMI 2017 Update 3


5-28 Module 5 – InTouch Alarms

View Alarm Groups In Tag Viewer


52. Click Runtime.
53. On the WindowViewer Special menu, click Tag Viewer.
54. In the watch window, right-click, and select Load Watch List.

55. Navigate to C:\Training and open My Watch List.


56. Create a new watch window named Alarms.
57. In the tag list, expand the Mixers alarm group, right-click Mixer100_Temperature_PV, and
select Add to Watch.

58. Click a blank space on the watch window, right-click and select Add Separator.

Wonderware Training
Lab 11 – Configuring InTouch Alarms 5-29

59. In the tag list, select $System.

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.

61. In the tag list, select the Mixers alarm group.

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.

63. In the tag list, select Mixer100_Temperature_PV.


64. From the Dotfield Name list on the right, drag Alarm to the watch list.
Mixer100_Temperature_PV.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.

InTouch HMI 2017 Update 3


5-30 Module 5 – InTouch Alarms

65. Add Tag_Discrete1.Alarm to the watch list.


Finally, you will inhibit all mixer alarms.
66. Add the MixerGroup_Inhibit tag to the watch list.

67. In the watch list, double-click MixerGroup_Inhibit.


The Modify Discrete Value dialog box appears.

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

Section 2 – Live Alarms Management


This section will describe alarm management, define alarm ack models, and discuss alarm query
syntax. This section will also explain of the .NET Alarm Client features, discuss alarm inhibition,
and compare alarm inhibition with alarm suppression.

Alarm Client Overview


The Alarm Client is a .NET control that allows the operator to see the state of alarms and events
and is built with functionality for sorting, acknowledging, and handling alarms. The Alarm Client
has been designed with defaults that meet industry standards and best practices of most
industries.
At runtime the Alarm Client supports interaction through standard menu and click functionality. The
Alarm Client automatically displays all of the alarms from the InTouch application using a default
alarm query that points to the $System master alarm group. This query an be configured to show
alarms from specific alarm groups in InTouch. Alarm Groups allow you to organize tags by area or
process.

InTouch HMI 2017 Update 3


5-32 Module 5 – InTouch Alarms

Alarm Client Run-Time Behavior


Run-Time Behavior for the Alarm Client changes the functionality at runtime. Features can be
enabled, disabled, and configured using the Run-Time Behavior animation of the control. These
include disabling UI features such as, which menu options appear in the right-click context menu,
or how queries and filters are stored in the Users profile when modified at runtime. For example,
you can disable the ability of users to modify the design time configured Queries and Filters. Or
you may allow operators to modify the queries and filters and have their changes loaded at
runtime when WindowViewer restarts. This option allows you to save user queries and filters, that
are configured by default

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

View Alarms in the Alarm Client


At runtime the Alarm Client displays each alarm as an individual row in its grid. Alarm rows are
displayed in color to indicate the current state of the alarm. Columns provide details such as which
user was on duty at the time the alarm occurred, the limit that triggered the alarm, which computer
node the alarm came from, and the time and date that the alarm occurred.

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.

Alarm Query Syntax


The Alarm Client supports the use of queries which look similar to the following:
\intouch!$System
The above query connects to WindowViewer on the current PC and obtains all live alarms. The
Alarm Client uses syntax like this to populate the display with alarm records that match the query.
By default, the Alarm Client is configured for current alarms only.
The Alarm Client allows alarm query syntax to include the space character as a separator between
alarm queries. For example: \intouch!group1 \intouch!group2. This query example would fill the
Alarm Client with alarms only from group1 and group2.
The alarm query syntax also supports retrieving alarms from other InTouch nodes. For example:
\\Server01\InTouch!$System will retrieve all InTouch alarms from the computer node named
Server01.
Alarm queries also support wild card characters. For example, \intouch!$System!Mixer* will
retrieve all alarms for tags with a name that begins with mixer.

InTouch HMI 2017 Update 3


5-34 Module 5 – InTouch Alarms

User Input Animation


User Input is a type of interactive animation in InTouch. This means that a user is able to click or
touch the screen to interact with a button or graphic. The User Input animation supports multiple
InTouch data types including: Boolean, analog, and string.

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

Lab 12 – Visualizing and Acknowledging Live


Alarms

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

InTouch HMI 2017 Update 3


5-36 Module 5 – InTouch Alarms

Add and Configure the Alarm Client


In the following steps, you will create a new symbol, and embed and configure the properties of an
Alarm Client.
1. In the ArchestrA Graphic Toolbox, Training toolset, create a new symbol named
CurrentAlarms, and open it for editing.

2. In the Tools pane, select the Alarm Client tool.

3. Click the canvas to place the Alarm Client.


4. Name the element LiveAlarms.

Wonderware Training
Lab 12 – Visualizing and Acknowledging Live Alarms 5-37

5. Double-click LiveAlarms to edit the animations.


The Edit Animations dialog box appears.

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.

InTouch HMI 2017 Update 3


5-38 Module 5 – InTouch Alarms

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

9. Click Name, and rename it to Tag.

10. With Tag selected, click the up arrow button until Tag appears below User1.

The Tag column is in the first position in the grid preview.

InTouch HMI 2017 Update 3


5-40 Module 5 – InTouch Alarms

11. In the Animations pane, select Run-Time Behavior.


The Run-Time Behavior animations pane appears.

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

13. Click OK.

InTouch HMI 2017 Update 3


5-42 Module 5 – InTouch Alarms

LiveAlarms will look similar to the following image.

Add Buttons to CurrentAlarms


Next, you will add buttons to the CurrentAlarms symbol and configure them to display different
sets of alarms in the Alarm Client.

14. In the Tools pane, select the Button tool.

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.

16. Label the button All.

17. In the Properties pane, name the button AllButton.


18. On the Element Style drop-down list, select Intensity1.

InTouch HMI 2017 Update 3


5-44 Module 5 – InTouch Alarms

19. Double-click AllButton to add animations.


20. Add an Element Style animation.

21. In the Element Style animations pane, select Boolean.


22. In the Boolean field, enter LiveAlarms.AlarmQuery == "\InTouch!$System".

Note: Case sensitivity is important for text entered inside of quotes.

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

25. Add a Pushbutton animation.

The Pushbutton animation details pane appears.


26. Click String.

InTouch HMI 2017 Update 3


5-46 Module 5 – InTouch Alarms

The Pushbutton String animations pane appears.

27. In the String field, enter LiveAlarms.AlarmQuery.


28. In the Action area, click Set.
29. In the Value1 field, enter \InTouch!$System.

30. Click OK.

Wonderware Training
Lab 12 – Visualizing and Acknowledging Live Alarms 5-47

31. Duplicate the AllButton.


32. Move the duplicate button to the right of the AllButton.
33. In the Properties pane, name the button MixersButton.
34. In the Text field, enter Mixers.

35. Double-click MixersButton to edit the animations.

36. In the Pushbutton animations pane, Value1 field, replace $System with Mixers.

InTouch HMI 2017 Update 3


5-48 Module 5 – InTouch Alarms

37. In the Animations pane, select Element Style.


38. In the Element Style animations pane, Boolean field, replace $System with Mixers.

39. Click OK.


40. Duplicate MixersButton, and place the duplicate to the right of MixersButton.
41. In the Properties pane, name the duplicate DiscreteAlarmTest.
42. In the Text field, enter Discrete Alarm Test.

43. Adjust the size of the button so the whole label is displayed.

Wonderware Training
Lab 12 – Visualizing and Acknowledging Live Alarms 5-49

44. Double-click DiscreteAlarmTest to edit the animations.


45. In the Element Style animations pane, Boolean field, enter InTouch:Tag_Discrete1.

46. In the Animations pane, select Pushbutton.


47. In the Pushbutton animations pane, States area, click Boolean.
48. In the Boolean field, enter InTouch:Tag_Discrete1.
49. In the Action area, select Toggle.

50. Click OK.

InTouch HMI 2017 Update 3


5-50 Module 5 – InTouch Alarms

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.

55. Double-click AckAll, and add a User Input animation.

Wonderware Training
Lab 12 – Visualizing and Acknowledging Live Alarms 5-51

The User Input animations pane appears.

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

57. Click OK.

InTouch HMI 2017 Update 3


5-52 Module 5 – InTouch Alarms

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.

60. Save and close CurrentAlarms.

Wonderware Training
Lab 12 – Visualizing and Acknowledging Live Alarms 5-53

Embed the Symbol


Next, you will embed and configure the new symbol in the Current Alarms window.
61. Embed CurrentAlarms in the Current Alarms window.

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.

InTouch HMI 2017 Update 3


5-54 Module 5 – InTouch Alarms

Test What You Have Built


Next, you will test the functionality of the Alarm Client and the configured buttons.
63. Click Runtime.
The All button is enabled so every tag in the InTouch application that is currently in alarm is
being displayed. This includes the $System alarm group and the Mixers alarm group.
The Discrete Alarm Test button is enabled. This sets the value of Tag_Discrete1 to True.
Because Tag_Discrete1 is set to alarm when on, or true, there is also a record in the Current
Alarm window for Tag_Discrete1. Note the Group column displays $System for
Tag_Discrete1.

Note: You may have to scroll down to view the Tag_Discrete1 record.

64. Click the Mixers button.


The All button is disabled and the Mixers button is enabled. Only the Mixers group alarms
display. In the Current Alarms list Tag_Discrete1 no longer appears because it does not
belong to the Mixers group.

65. Click the All button.

Wonderware Training
Lab 12 – Visualizing and Acknowledging Live Alarms 5-55

66. Click the Ack All button.


The confirmation message appears.

67. Click Yes.


This will clear all of the alarms which have returned to normal prior to using the Ack All button.
68. Verify that Tag_Discrete1 appears as an acknowledged tag that has not returned to normal.

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.

InTouch HMI 2017 Update 3


5-56 Module 5 – InTouch Alarms

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.

After a moment, the Ack Comment dialog box appears.


78. In the Comment field, enter This test is complete.

79. Click OK.


Tag_Discrete1 has been acknowledged with a comment.

80. Open Tag Viewer, and set MixerGroup_Inhibit to False.


81. Close Tag Viewer.
82. Click Development!.

Wonderware Training
Section 3 – Historical Alarms Management 5-57

Section 3 – Historical Alarms Management


This section will explain how to record alarms in a database and retrieve those alarms to view in
the Alarm Client.

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).

Alarm DB Logger Manager


The Alarm DB Logger Manager is a wizard utility used to configure the Alarm DB Logger. This
utility provides buttons to start and stop the Alarm DB Logger. The executable for the Alarm DB
Logger Manager, named almlogwiz.exe, may be closed after starting the Alarm DB Logger
(wwalmlogger.exe). The Alarm DB Logger does not have a console user interface so it does not
show an icon on the task bar while it is running.

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.

InTouch HMI 2017 Update 3


5-58 Module 5 – InTouch Alarms

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.

Running Alarm DB Logger as a Service


You may configure Alarm DB Logger Manager to run as a service. This allows the Alarm DB
Logger to start without a human present to log on to the console. Additionally, InTouch alarms
generated while running WindowViewer in Terminal (RDP) Sessions may also be logged into the
alarm database.
The following limitations apply.
 The combination of Alarm DB Logger configured as a service and InTouch running locally
as a console application is not supported. If InTouch needs to run in the Console session,
the AlarmDB Logger must be run as a Normal Application. This means WindowViewer
must be configured to run as a Service in addition to configuring Alarm DB Logger to run
as a service.
 If Alarm DB Logger is configured to run as a service for InTouch HMI application it cannot
also serve to log alarms from Application Server (InTouch for System Platform - Managed
InTouch).

InTouch HMI 2017 Update 3


5-60 Module 5 – InTouch Alarms

Supported Queries When AlarmDbLogger is Configured as a Service


For InTouch alarms from Terminal Sessions
\\<TerminalServerNodeName>:<TerminalSessionIPAddress>\InTouch!$System
Where:
 "TerminalServerNodeName is the computer name of the Terminal Server Node
 "TerminalSessionIPAddress is the IPAddress of the TS Client initiating the session. This is
the session IP of the alarm provider. This is not the IP address of the terminal server.
 For example
 "Terminal Server Computer name: TSNode1
 "Terminal Server IP Address: 10.2.1.1
(As returned by an < ipconfig > command executed from the console)
 "Terminal Session IP Address: 10.2.1.67
(This is the IP address of the terminal client as returned by an < ipconfig> command
executed from the terminal session. You can also rely on the InTouch function
TSEGetClientId () executed from the InTouch Application in a Terminal Session.)

Wonderware Training
Lab 13 – Visualizing and Filtering Historical Alarms and Events 5-61

Lab 13 – Visualizing and Filtering Historical


Alarms and Events

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

InTouch HMI 2017 Update 3


5-62 Module 5 – InTouch Alarms

Configure a Tag to Log Events


In the following steps, you will configure the MixerGroup_Inhibit tag to log events. This will allow
you to log and display when mixer alarms are inhibited.
1. Close WindowViewer.
2. In the WindowMaker Tagname Dictionary, select the MixerGroup_Inhibit tag.
3. Check the Log Events check box.
4. In the Priority field, enter 999.

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!.

Configure and Start the Alarm DB Logger


Next, you will open the Alarm DB Logger Manager and configure it to record historical alarms and
events.
8. In the Tools pane, expand Applications, and double-click Alarm DB Logger Manager.

Wonderware Training
Lab 13 – Visualizing and Filtering Historical Alarms and Events 5-63

The Alarm DB Logger Manager dialog box appears.

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.

InTouch HMI 2017 Update 3


5-64 Module 5 – InTouch Alarms

11. In the Server Name field, enter your Engineering node name.

Note: Your instructor will provide the Engineering node name.

12. In the Database name field, ensure the default WWALMDB is entered.
13. Click Create.
A Success message appears.

14. Click OK.


15. Click Next.

Wonderware Training
Lab 13 – Visualizing and Filtering Historical Alarms and Events 5-65

The Alarm DB Logger Manager - Query Selection dialog box appears.

16. Retain the defaults and click Next.


The Alarm DB Logger Manager - Advanced Setting dialog box appears.

17. Retain the defaults, and click Finish.

InTouch HMI 2017 Update 3


5-66 Module 5 – InTouch Alarms

18. In the Alarm DB Logger Manager, click Start.

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.

Create the Symbol to View Historical Alarms and Events


Next, you will duplicate the CurrentAlarms symbol, and configure the new symbol to display and
query historical alarms and events from the Alarm DB Logger in runtime.
20. In the ArchestrA Graphic Toolbox, Training toolset, right-click the CurrentAlarms symbol,
and select Duplicate.
Symbol duplication may take a few moments.

Wonderware Training
Lab 13 – Visualizing and Filtering Historical Alarms and Events 5-67

21. Name the new symbol HistoricalAlarmsEvents.


22. Open HistoricalAlarmsEvents for editing.
23. On the canvas, delete all of the button elements.

24. Rename LiveAlarms to HistAlarms.

InTouch HMI 2017 Update 3


5-68 Module 5 – InTouch Alarms

25. Double-click HistAlarms to edit the animations.


26. In the Alarm Mode animations pane, Client Mode drop-down list, select Historical Alarms
and Events.

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.

29. Click Test Connection.


A Connection successful message appears.

30. Click OK.


31. In the Animations pane, select Queries and Filters.

The Queries and Filters animations pane appears.

InTouch HMI 2017 Update 3


5-70 Module 5 – InTouch Alarms

32. In the top-right corner of the Queries and Filters animations pane, click the Add new query
button.

The Add Query or Filter dialog box appears.


33. In the Query or Filter Name field, enter Non Mixers ACK_RTN.

Wonderware Training
Lab 13 – Visualizing and Filtering Historical Alarms and Events 5-71

34. In the name list, select State.

35. Click the right arrow button to add State to the filter definition list.
36. In the filter definition list, select State.

The State details area is enabled on the right.

InTouch HMI 2017 Update 3


5-72 Module 5 – InTouch Alarms

37. On the Value drop-down list, select ACK_RTN.

38. Click Set to configure the option.


State = 'ACK_RTN' is displayed in the filter definition list.

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.

40. In the filter definition list, select Group.


41. On the Group details area, Operator drop-down list, select !=.
The operator, != indicates not equal to.
42. In the Value field, enter Mixers.

InTouch HMI 2017 Update 3


5-74 Module 5 – InTouch Alarms

43. Click Set to configure the option.


The filter definition is updated.

44. Click OK.


In the Queries list, the new query appears.

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.

46. Add State to the filter definition list.


47. In the filter definition list, select State, and configure the area to the right as follows:

Operator: =
Value: UNACK_RTN

48. Click Set.

49. Add Tag to the filter definition list, select Tag, and configure the area to the right as follows:

Operator: =
Value: Mixer100_Temperature_PV

InTouch HMI 2017 Update 3


5-76 Module 5 – InTouch Alarms

50. Click Set.

51. Click OK.


The Queries and Filters list shows the newly added queries.

Wonderware Training
Lab 13 – Visualizing and Filtering Historical Alarms and Events 5-77

52. In the Animations pane, select Run-Time Behavior.


53. In the Run-time Behavior animations pane, Queries and filters conflict resolution area,
uncheck the Overwrite Design Time Queries and Filters check box.
54. In the Show Context Menu area, uncheck the Ack Selected check box.
Historical alarms and events cannot be acknowledged.
55. Check the Queries and Filters check box.

56. Click OK.


57. Save and close HistoricalAlarmsEvents.

InTouch HMI 2017 Update 3


5-78 Module 5 – InTouch Alarms

Embed the Symbol in the Window


Next, you will embed and configure the HistoricalAlarmsEvents symbol in the Historical Alarms
and Events window.
58. Close the Current Alarms window.
59. Open the Historical Alarms and Events window.
60. Embed HistoricalAlarmsEvents in the Historical Alarms and Events window.
61. In the Properties pane, set MaintainAspectRatio to False.
The HistoricalAlarmsEvents symbol fills the frame window.

Wonderware Training
Lab 13 – Visualizing and Filtering Historical Alarms and Events 5-79

Test What You Have Built


Next, you will use the Historical Alarms and Events window to display the results of the queries
and filters defined earlier in this lab. Then, you will use the current alarm client and Tag Viewer to
generate records to be queried and displayed by the historical alarm client.
62. Click Runtime.
In the Historical Alarms and Events window, the list of historical alarms are displayed in red
and blue, and events are displayed in brown.

63. In the Menu window, click the Alarms button.


64. Open Tag Viewer, load My Watch List, and set MixerGroup_Inhibit to True.
65. In the Current Alarms window, click the Tag_Discrete1 row to select it.
66. Right-click the selected row, and select Ack Selected.

The Ack Comment dialog box appears.


67. Enter a comment, and click OK.

InTouch HMI 2017 Update 3


5-80 Module 5 – InTouch Alarms

68. In the Current Alarms window, click the Discrete Alarm Test button two times.

69. Click the Tag_Discrete1 row to select it.


70. Right-click the selected row, and select Ack Selected.
71. Enter a comment and click OK.
72. In the Menu window, click the Events button.
73. In the Historical Alarms and Events window, right-click the HistoricalAlarmsEvents
symbol, and select Queries and Filters.

After a moment, the Query and Filter Favorites dialog box appears.

Wonderware Training
Lab 13 – Visualizing and Filtering Historical Alarms and Events 5-81

74. Check the Non Mixers ACK_RTN check box.

75. Click OK.


You can view the history of the Tag_Discrete1 tag.

76. Use Tag Viewer to set MixerGroup_Inhibit to False, and then close Tag Viewer.

InTouch HMI 2017 Update 3


5-82 Module 5 – InTouch Alarms

77. In the Menu window, click the Alarms button.


78. In the Current Alarms window, click the Ack All button.

79. Click Yes.

80. In the Menu window, click Events.


81. In the Historical Alarms and Events window, right-click the HistoricalAlarmsEvents
symbol, and select Queries and Filters.

Wonderware Training
Lab 13 – Visualizing and Filtering Historical Alarms and Events 5-83

82. Check the Mixer100_Temperature_PV UNACK_RTN check box.


83. Click OK.
All of the Mixer100_Temperature_PV alarms that match the criteria are displayed.

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.

InTouch HMI 2017 Update 3


5-84 Module 5 – InTouch Alarms

The Add Query or Filter dialog box appears.


86. In the Query or Filter Name field, enter Events.

87. Add Class to the filter definition list.


88. Select Class, and in the Class details pane, Value field, enter Event.
89. Click Set.

90. Click OK.

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.

92. Click OK.


The MixerGroup_Inhibit event has been recorded. You may have to scroll down to locate
MixerGroup_Inhibit on the list.

InTouch HMI 2017 Update 3


5-86 Module 5 – InTouch Alarms

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.

An options list appears.

98. In the options list, select (Custom).


The Custom Filter dialog box appears.

99. In the Custom Filter dialog box, to the right of Alarm Duration, click the drop-down arrow,
and select > Greater than.

InTouch HMI 2017 Update 3


5-88 Module 5 – InTouch Alarms

100.In the ((DBNull)) field, enter 0.


This number represents a time mask displaying days, hours, minutes, seconds, and
milliseconds. The actual characters that appear in the mask are based on the last row
highlighted when you click the runtime query filter.
101.In the same field, enter 000 00:00:30.000.

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

Section 1 – (Optional Path 1) InTouch History and Real-Time


Trending
Optional Path 1 has been written for legacy InTouch history users. Select this learning path to
learn how to use InTouch historical logging.
This section will discuss the built-in InTouch historical logging features. The features include how
to enable InTouch history, visualizing InTouch history, and using HistData for exporting historical
logs to .csv files. This section will go on to explain how to use the Trend Client .NET control for
real-time trending visualization.

InTouch Historical Logging Overview


InTouch Historical Logging is built-in to InTouch HMI. Configuration of historical logging is done in
three phases:
1. Enable historical logging
2. Enable log data for each tag
3. Build a historical display window
In this section you will record historical data to .lgh and .idx files and retrieve historical data from
these files to display as traces on a chart. Finally, you will use the HistData wizard to write to a .csv
file which can be opened in Microsoft Excel.

Configure Historical Logging


To start historical logging you must enable historical logging in the Historical Logging Properties
dialog box. Historical Logging Properties are global settings which allow you to enable historical
logging, determine how long you will keep data for, and determine where on your network your
data will be stored.

InTouch HMI 2017 Update 3


6-4 Module 6 – Data Logging and Trending

Enable Log Data Per Tag


Individual tag data can be recorded to the historical log files when the log data feature is enabled.
This setting can be done on a tag by tag basis in the Tagname Dictionary, or in bulk by using the
DB Load feature.

Visualize Historical Data


InTouch provides four trend wizards which are used to construct a historical logging window.
These wizards allow you to retrieve and visualize your historical data at runtime.
 The first wizard is a chart which shows your data as pens or traces representing the
values of each tag. A single pen color is used for each tag and up to eight tags can be
displayed at one time.
 The second wizard is a zoom and pan wizard, which allows you to scroll back in time
and to zoom in and out on the pens in the chart.
 The third wizard is a legend which simply allows you to identify which color belongs to
which tag.
 The final wizard is the HistData wizard. This wizard communicates with the HistData
server which must be running on the same computer node as the InTouch application.
The purpose of the HistData server is to create a .csv file containing rows and
columns of data that represents the current information that is displayed on the chart.
The .csv file can be opened in Microsoft Excel for viewing.

How InTouch Historical Logging Works


When historical logging is enabled, each day at midnight two files are created. The files which are
created are .lgh, which contains the data. The second file is .idx which is an index for quick lookup
of tag information. An entry is recorded in the data file each time the value of a tag changes. This
is named delta storage. Additionally, WindowViewer writes one record every hour for every tag that
has been enabled for historical logging. This is named cyclic storage.

Trend Client Overview


Real-time trending in InTouch is done using the Trend Client. The Trend Client is a .NET control
which must be added to an ArchestrA symbol. The functionality of the Trend Client includes real-
time plotting of tag data, and a backfill feature which leverages InTouch history. Backfill allows the
chart to be instantly filled with data while waiting for real-time information to be plotted.

Configure Real-Time Trending


After the .NET Trend Client has been embedded into a symbol, its animations are then configured
to determine the following:
 Pens
 Appearance
 Options
 Historical Sources

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.

InTouch HMI 2017 Update 3


6-6 Module 6 – Data Logging and Trending

Configure Appearance and Options


The appearance and behavior of the Trend Client is determined by the Appearance and Options
settings. For example, you can change the background color or image used in the chart, you can
turn on a legend to display which pens are configured, or determine the rate at which the chart
updates real-time data.
 Single tag mode - hides all pens except the pen selected in the legend
 Background color - supports gradients, images, solid colors, textures, and so on
 Border Color - configures the color of the border for the entire chart area
 Highlight pen - the currently selected pen turns bright yellow and double-think to stand
out among all of the pens on the chart
 X time axis - specifies the time settings for the chart
 Y value axis - specifies the tag scale information on the chart

Create an InTouch History Connection


You can get data from InTouch .lgh files using the Historical Sources animation. Configure the
file path to the InTouch history data, which will be used to backfill traces on the chart when the
chart is initially displayed. This allows the chart to be useful without having to wait for real-time
data to plot across the entire timespan of the chart. If the chart remains on the screen long
enough, eventually real-time data will fill the entire chart, and replace the backfilled portions.
Once a historical source to InTouch history has been defined each pen that is added to the chart
must use this historical source to backfill its individual data.

Wonderware Training
Lab 14 – Logging Historical Data Using InTouch History 6-7

Lab 14 – Logging Historical Data Using


InTouch History

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

InTouch HMI 2017 Update 3


6-8 Module 6 – Data Logging and Trending

Enable Historical Logging


In the following steps, you will enable and configure historical logging properties. You will then
specify where the log files should be stored.
1. Close WindowViewer.
2. In the WindowMaker Tools pane, ensure Configure is expanded, and then double-click
Historical Logging.

The Historical Logging Properties dialog box appears.


3. Check the Enable Historical Logging check box.

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.

Configure Tags to Log Data


Next, you will add the log data feature to several tags.
6. In the Tagname Dictionary, select Mixer100_Agitator_PV.
7. Check the Log Data check box.

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.

InTouch HMI 2017 Update 3


6-10 Module 6 – Data Logging and Trending

Build a Window with Historical Trend Wizards


Next, you will create a new window and use the wizard tool to add and configure three unique
Historical Trend wizards to the window.
11. On the WindowMaker File menu, select New Window from Template.
12. In the Template Window Browser, double-click Content_NonFrame.
13. Name the window InTouch History.

14. Click OK.


15. Close the Mixer window.
16. In the Menu window, duplicate a button, and change the label to History.

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.

Your screen will look similar to the following image.

18. On the toolbar, click the Wizards button.

InTouch HMI 2017 Update 3


6-12 Module 6 – Data Logging and Trending

The Wizard Selection dialog box appears.


19. In the left pane, select Trends.
20. In the right pane, select Hist Trend w/Scooters and Scale.

21. Click OK.


22. Place Hist Trend w/Scooters and Scale on the top-left corner of 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.

The Hist Trend and Pen Scale fields update.


25. Click Pens.
The Trend Pens dialog box appears.

26. In the Pen 1 field, double-click the empty field.


A list of tags that have log data enabled appears.

InTouch HMI 2017 Update 3


6-14 Module 6 – Data Logging and Trending

27. Select Mixer100_Agitator_PV.

28. Click OK.


29. Configure additional pens as follows:

Pen 2: Mixer100_Level_PV
Pen 3: Mixer100_Temperature_PV

30. Click OK.


31. In the Historical Trend Chart Wizard, click OK.

32. Click the Wizards button.

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.

34. Click OK.


35. Place Trend Zoom/Pan Panel below Hist Trend w/Scooters and Scale.

InTouch HMI 2017 Update 3


6-16 Module 6 – Data Logging and Trending

36. Double-click Trend Zoom/Pan Panel.


The Trend Panel Wizard dialog box appears.
37. Click Suggest.
The Hist Trend and Pan Minutes fields update.
38. Rename both tags by removing the 1 that was added.

The HistTrend tag is used to communicate between the wizards, therefore the tagname must
be the same.

39. Click OK.

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.

41. Click the Wizards button.


42. Select Trends, and then select Trend Pen Legend.

43. Click OK.

InTouch HMI 2017 Update 3


6-18 Module 6 – Data Logging and Trending

44. Place the Trend Pen Legend to the right of the chart.

45. Double-click Trend Pen Legend.


46. In the Trend Legend Wizard dialog box, click Suggest.
47. In the Hist Trend and Pen Scale fields, remove the 1 that was added.
48. Click OK.

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.

50. Double-click the duplicate to configure the legend.


51. In the Pen Number field, enter 2.
52. In the Colors area, Trend Pen option, click the box to the right and select red.

53. Click OK.

InTouch HMI 2017 Update 3


6-20 Module 6 – Data Logging and Trending

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.

57. Click OK.


The History window will look similar to the following image.

Wonderware Training
Lab 14 – Logging Historical Data Using InTouch History 6-21

Test What You Have Built


Finally, you will test the Trend Wizard functionality in runtime.
58. Click Runtime.

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.

InTouch HMI 2017 Update 3


6-22 Module 6 – Data Logging and Trending

61. Click the Zoom In button.


The chart displays zoomed in.

Wonderware Training
Lab 14 – Logging Historical Data Using InTouch History 6-23

62. Slide the left scooter slowly to the right.


The legend values for each pen change as you drag the left scooter across the view, based on
the slider location.

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!.

InTouch HMI 2017 Update 3


6-24 Module 6 – Data Logging and Trending

Enable Log Data for Additional Mixer Tags


Next, to save time, you will import a .csv file to set Log Data for Mixers 200-400. This will enable
historical logging for tags that will be used in future labs in this course.
65. Close WindowViewer.
66. Close WindowMaker.
67. Open the InTouch Application Manager.

68. Ensure InTouch Training Application is selected and click the DBLoad button.

The Database Load dialog box appears.


69. Click Yes.

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.

71. Click OK.


A Load successful message appears.

72. Click OK.

73. Open the InTouch Application Manager.


74. Ensure InTouch Training Application is selected and start WindowMaker.
The Windows to Open dialog box appears.
75. Click OK.
76. In WindowMaker, click Runtime.
This will ensure that data will continue to be logged.
77. Click Development!.

InTouch HMI 2017 Update 3


6-26 Module 6 – Data Logging and Trending

Wonderware Training
Lab 15 – Trending Real-Time Data 6-27

Lab 15 – Trending Real-Time Data

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

InTouch HMI 2017 Update 3


6-28 Module 6 – Data Logging and Trending

Build a Real-Time Window


In the following steps, you will create a real-time window.
1. In WindowMaker, from the File menu, select New Window from Template.
2. In the Template Window Browser, double-click Content_Frame.
3. Name the window REALTime.

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

Create the Trend Client Symbol


7. In the Training toolset, create a new symbol named Realtime, and open it for editing.

8. In the Tools pane, select the TrendClient tool.

9. Click the canvas to place the element.


10. Name the element Realtime.
11. Double-click Realtime to edit the animations.
12. In the Animations pane, select Historical Sources.

13. In the top-right corner of the Historical Sources animations pane, click the Add Row
button.

InTouch HMI 2017 Update 3


6-30 Module 6 – Data Logging and Trending

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.

22. In the Description field, enter Level.

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.

InTouch HMI 2017 Update 3


6-32 Module 6 – Data Logging and Trending

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:

Pen Name: Agitator


Expression or Reference: InTouch:Mixer100_Agitator_PV
Pen Details
Description: Agitator
Units: <blank>
Min: 0
Max: 1

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

InTouch HMI 2017 Update 3


6-34 Module 6 – Data Logging and Trending

32. In the Animations pane, select Appearance.

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

37. In the Animations pane, select Options.

38. In the Options animations pane, check the Show pen selector check box.

39. Click OK.

InTouch HMI 2017 Update 3


6-36 Module 6 – Data Logging and Trending

The Realtime symbol will look similar to the following image.

40. Save and close Realtime.


41. Embed the Realtime symbol in the REALtime window.
42. In the Properties pane, set the MaintainAspectRatio property to False.

Wonderware Training
Lab 15 – Trending Real-Time Data 6-37

Test What You Have Built


Finally, you will test the REALTime window you just built.
43. Click Runtime.
The chart is backfilled immediately with InTouch history and begins scrolling toward the left as
new real-time tag data is plotted.

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.

InTouch HMI 2017 Update 3


6-38 Module 6 – Data Logging and Trending

Wonderware Training
Section 2 – (Optional Path 2) Using Historian with InTouch 6-39

Section 2 – (Optional Path 2) Using Historian with InTouch


Optional Path 2 has been written for Historian Server users. Select this learning path to learn how
to use Historian data with InTouch.
This section will explain how to import tags into Historian Server using the Tag Importer Wizard in
the ArchestrA System Management Console. The section will go on to describe how to build a
Historian Client Trend display in InTouch.

Overview of Historian Server


Historian Server is a real-time process historian. Historian Server extends the functionality of
Microsoft SQL Server, increasing acquisition speed, reducing storage volume, and extending time
series query functionality. Historian Server bridges the gap between a real-time high-volume plant
monitoring environment and an open, flexible business information environment.
Historian Server acquires plant data from high-speed I/O, DA, and OI Servers, as well as InTouch,
Application Server, and intelligent devices. Historian Server compresses and stores data in real-
time and responds to requests for this data.

InTouch HMI 2017 Update 3


6-40 Module 6 – Data Logging and Trending

Relational Databases and Historian Server


In a Relational Database Management System (RDBMS) information is stored in multiple tables
that are related or linked together. Data can be inserted (written) and selected (read) from an
RDBMS using Structured Query Language (SQL), the language used to communicate with
relational databases.
Historian Server is a real-time process historian which is tightly coupled to Microsoft SQL Server
so it can leverage all of the features of Microsoft SQL Server. These features include database
security, replication, backups, and compatibility with most SQL utilities and tools. When using SQL
or other tools to work with Historian Server the Historian data is presented and accessible as
though it were an actual database in order to maximize compatibility and support.
Historian Server configuration data is relatively static and does not change at a real-time rate.
Over the life of the server, configuration changes such as adding and deleting tags, changing
descriptions, altering engineering ranges, and modifying storage details. To contain this static
data, Historian Server uses a Microsoft SQL Server database, named the Runtime database, to
store configuration information.

Limitations of Relational Databases


Though MSSQL supports high-throughput and time-series data there are significant differences
between a typical database management system and Historian Server as a real-time process
historian. Typical relational databases are not viable solutions for storing plant data because of the
following limitations:
 They cannot handle the volume of data produced by plants
 They cannot handle the storage rate of plant data
 SQL does not effectively handle time-series data
Consider a plant with 60,000 tags changing every second or faster. That means that a minimum of
60,000 rows of data must be inserted into the database each second, or risk misrepresenting the
real-time history of what happened in the plant. Such a transaction rate is not sustainable using
SQL Server.
It is not merely a matter of having enough storage space to hold that much data; it is often a
requirement that historical data be robustly protected, which multiplies the amount of storage
required for backups and mirroring. Some industries impose mandatory regulations to maintain
several years’ worth of data, which further magnifies the overall storage requirements.
Time series data is ordered by time, and most historian data only represents samples from a
continuum of real data where not all data is of equal significance. Consider the following examples
which would fail when using SQL Server by itself:
 If an instrument reports a value time stamped at 7:59:58.603 and a user queries the
relational database for the value at 8:00:00.000, no data will be returned because there
are no records stored for precisely that time. A relational database does not recognize a
time continuum.
 If a temperature was 21.0º C and two minutes later was 23.0º C, a relational database has
no inherent ability to infer that halfway between these two samples the temperature was
approximately 22.0º C. The relational database will return a null result.
Historian Server solves all of these problems inherent with SQL Server.

Wonderware Training
Section 2 – (Optional Path 2) Using Historian with InTouch 6-41

Managing and Configuring Historian Server with SMC


The System Platform Management Console uses the Management Console and Configuration
Editor nodes for a Historian Server.
The Management Console, Status section shows if the server is running, which modules are
running, when the server was started, the number of licensed tags, and a log of events.

The Configuration Editor can be used to add tags which will be historized, delete tags, and
modify the definitions of tags.

InTouch HMI 2017 Update 3


6-42 Module 6 – Data Logging and Trending

Importing InTouch Tags using the Configuration Editor


The Import Tags feature of the Configuration Editor is used to create tags from an InTouch
Tagname Dictionary file, Tagname.x. Imported tags will then be recorded by Historian Server.
Importing a tagname database eliminates the need to manually configure I/O Server and tag
definitions for both the InTouch HMI software and the historian. Information in the tagname
database is automatically mapped to the appropriate tables within the historian Runtime database
as part of the import process.
You can import tagname databases from multiple InTouch nodes, but you can only import one
application from each node. The name of the node becomes part of the definition and the
namespace must be unique.
To perform an import, you must have administrative permission in Microsoft SQL Server. The SMC
uses this authentication while working with Configuration Editor. Use the Configuration Editor to
import tag definitions and afterwards commit these changes to the Historian Server, and then the
historian acquires data for these tags.

Wonderware Historian Client Trend


Wonderware Historian Client Trend is a client application that enables you to query tags from a
Wonderware Historian database and plot them on a graphical display. Trend supports two different
chart types: a regular trend curve and an XY scatter plot.
After you add tags to a trend chart, you can manipulate the display in a variety of ways, including
panning, zooming, and scaling. You can customize any trend by configuring display options and
set general options for use with all trends.
Before Trend can be used to query tag information from the database, the server must be running
and you must have security access.

Importing DLLs in WindowMaker


The trend tool has both a stand-alone application and a control that can be embedded in a window
in InTouch. To use this control the Historian Client must be installed and licensed. This includes
the files needed to manage this control in InTouch.
The DLL named aaHistClientTrend is a control that provides essential interactive functionality of
the Wonderware Historian Client Trend for use in container applications, such InTouch. In
InTouch, you can select this control within WindowMaker when you create your runtime graphical
user interface. This DLL is installed automatically when you install Wonderware Historian Client.

Using the Trend in InTouch


When using Wonderware Historian Client Trend in InTouch runtime, the user interface supports
simple drag, drop, and click operations which an InTouch user can use to analyze their plant data.
For example, tags can be dragged from the Tag Picker into the chart to instantly display historical
information for that tag. The toolbars then allow pan, zoom, and scaling of the tag data.
The Wonderware Historian Client Trend allows for both historical analysis and real-time data
plotting. By clicking the Live Mode button you can put the trend in continuous scroll mode. This
allows you to play back plant history at any point in time or plot real-time data coming from these
tags. In this way the Wonderware Historian Client Trend supports both historical and real-time
data plots.

Wonderware Training
Lab 16 – Logging Historical Data using Historian 6-43

Lab 16 – Logging Historical Data using


Historian

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

InTouch HMI 2017 Update 3


6-44 Module 6 – Data Logging and Trending

Import InTouch Tags into Historian Server


In the next steps, you will use the Historian Tag Importer Wizard in the SMC to import tags.
1. Close WindowViewer.
2. Close WindowMaker.
3. Open the SMC.
4. Expand Historian.
5. Expand Historian Group.
6. Expand the name of the registered Historian (Engineering node).

Note: Your instructor will provide the name of this node.

7. Click Configuration Editor to select it.


8. Right-click Configuration Editor, and select Import Tags.

Wonderware Training
Lab 16 – Logging Historical Data using Historian 6-45

The Tag Importer Wizard - Welcome dialog box appears.

9. Click Next.
The Tag Importer Wizard - Already Imported Nodes dialog box appears, indicating that no
tags from an InTouch application have been imported.

10. Click Add.

InTouch HMI 2017 Update 3


6-46 Module 6 – Data Logging and Trending

The Select Tagname.x dialog box appears.


11. Navigate to C:\Training\InTouch Training Application, and select tagname.x.

12. Click Open.


The Tag Importer Wizard - InTouch Node Information dialog box appears.
In the example below, S01ENG is the Historian Server node.

13. Click Next.

Wonderware Training
Lab 16 – Logging Historical Data using Historian 6-47

The Tag Importer Wizard - Tag Duplicates dialog box appears.

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.

15. Click OK.

InTouch HMI 2017 Update 3


6-48 Module 6 – Data Logging and Trending

The Tag Importer Wizard - Tag Duplicates dialog box shows the Bypass Uniqueness
String check box checked.

16. Click Next.


The Tag Importer Wizard - Filter Tags dialog box appears.
17. In the Categories area, check the All check box.

Wonderware Training
Lab 16 – Logging Historical Data using Historian 6-49

18. In the Logged Only for Category area, click the Topics button.

The Tag Importer - Select Topics dialog box appears.


19. In the Tag Importer - Select Topics dialog box, click the remove all button.

All of the topics are moved to the Available list.

InTouch HMI 2017 Update 3


6-50 Module 6 – Data Logging and Trending

20. Select the topic that starts with PLCSim.


21. Click the add button.

The PLCSim topic is added to the To Be Imported list.

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.

24. Leave the defaults and click Next.


The Tag Importer Wizard - Final Confirmation dialog box appears.

25. Click Finish.

InTouch HMI 2017 Update 3


6-52 Module 6 – Data Logging and Trending

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.

27. Click OK.

Commit Pending Changes


Next, you will commit these changes to the Historian Server database.
28. Select Configuration Editor.
29. Right-click Configuration Editor, and select Commit Pending Changes.

Wonderware Training
Lab 16 – Logging Historical Data using Historian 6-53

The Commit Pending Changes - Confirmation dialog box appears.


30. Click Commit.

A message appears confirming the database changes were committed.

31. Click OK.

InTouch HMI 2017 Update 3


6-54 Module 6 – Data Logging and Trending

Verify Data Acquisition from InTouch


Finally, you will start WindowViewer and after it is open you will verify data acquisition in the SMC.
32. Start the InTouch Application Manager, and open the InTouch Training Application in
WindowMaker.
The Windows to Open dialog box appears.
33. Click OK.
34. Click Runtime.
35. In the SMC, expand Management Console, and click Data Acquisition.

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

Lab 17 – Building a Historian Client Trend


Display

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

InTouch HMI 2017 Update 3


6-56 Module 6 – Data Logging and Trending

Import the Historian Client Trend .NET Control


In the following steps, you will import the Historian Client Trend .NET control into WindowMaker.
1. Close WindowViewer.
2. On the WindowMaker File menu, select Import | Client Control.

The Import Client Control(s) dialog box appears.

Wonderware Training
Lab 17 – Building a Historian Client Trend Display 6-57

3. Navigate to C:\Program Files (x86)\Common Files\ArchestrA, scroll down, and click


aaHistClientTrendControl.dll.

4. Click Open to begin the import process.


The Import Client Controls dialog box appears.

After a moment, the import is completed.

5. Click Close.

InTouch HMI 2017 Update 3


6-58 Module 6 – Data Logging and Trending

Create the Trend Symbol


Next, you will create a new Trend symbol.
6. In the Training toolset, create a new symbol named Trend, and open it for editing.
7. Click Embed Graphic.
8. In the Galaxy Browser, ensure the top most InTouch Training Application node is selected.
9. Select the aaTrendControl.

10. Click OK.


11. Click on the canvas to place the control.
The new control appears.

12. Save and close the symbol.

Wonderware Training
Lab 17 – Building a Historian Client Trend Display 6-59

Create the Trend Window


Next, you will create a new window and embed Trend in the window.
13. In WindowMaker, on the File menu, select New Window from Template.
14. In the Template Browser window, double-click Content_Frame.
15. Name the window Trend.

16. Click OK.


The Trend window appears.
17. Embed the Trend symbol in the Trend window.
18. In the Properties pane, set the MaintainAspectRatio to False.

19. In the Menu window, add a Trend navigation button, with an animation link to open the Trend
window.

InTouch HMI 2017 Update 3


6-60 Module 6 – Data Logging and Trending

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

Connect to Historian Server


The first time you connect to the Trend control you must specify connection information. The
Wonderware Historian Client maintains an active connection with the Historian Server. When the
Trend window closes and reopens, the Trend control will automatically reconnect to the Historian
Server. Next, you will connect to Historian Server.
21. In the Trend window, click the Configure the servers button.

The Server List Configuration dialog box appears.

InTouch HMI 2017 Update 3


6-62 Module 6 – Data Logging and Trending

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).

23. In the Login area, ensure Windows Integrated is selected.


In the training classroom, your Windows login is used to connect as an administrator of
Microsoft SQL Server.

Note: If special instructions are required, your instructor will provide this information.

24. Click Add.

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.

25. Click Close.

InTouch HMI 2017 Update 3


6-64 Module 6 – Data Logging and Trending

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.

27. In the Tags list, locate Mixer100_Agitator_PV, and select it.

Wonderware Training
Lab 17 – Building a Historian Client Trend Display 6-65

28. Drag Mixer100_Agitator_PV onto the chart.


The Agitator tag is now plotted on the chart.

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.

InTouch HMI 2017 Update 3


6-66 Module 6 – Data Logging and Trending

Manipulate Time Duration


Next, you will manipulate the trend by changing the Duration of the data displayed.
30. On the Time toolbar, Duration drop-down list, select 4 hours.

The trend chart updates to display the 4-hour time span.


31. On the Duration drop-down list, click 1 minute.

The trend chart updates to display the 1 minute time span.

Wonderware Training
Lab 17 – Building a Historian Client Trend Display 6-67

Enable Live Mode


Finally, you will view trend data in one second intervals.
32. Click the Enable or disable live or replay mode button.

The trend chart begins scrolling in one second intervals.


33. Click Development!.
34. In WindowMaker, close the Trend window.

InTouch HMI 2017 Update 3


6-68 Module 6 – Data Logging and Trending

Wonderware Training
Section 3 – (Optional Path 1 and 2) Trend Pen 6-69

Section 3 – (Optional Path 1 and 2) Trend Pen


This section will explain how to use the Historian Client Trend .NET control in InTouch, import a
.NET client control library file using WindowMaker and use Live Mode to continuously refresh the
trend with current data.

Trend Pen Overview


A trend line gives operators a quick visual snapshot of a process value over a defined period. A
Trend Pen shows a succession of process values as a trend line consisting of current and
historical data updated at a minimum of one second intervals.

Understanding the Types of Trend Plots


You can configure two types of Trend Pen plots. A Line plot draws a line between each successive
data point during the trend period.

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.

InTouch HMI 2017 Update 3


6-70 Module 6 – Data Logging and Trending

Understanding the Types of Trend Pen Periods


A trend time period is the interval of process values shown on the X-axis of the trend during run
time, which consists of a start time, end time, and a duration.
You can configure two types of Trend Pen periods.
 Moving time period In a Moving trend period, the start time of a trend period is the current
time. The end time is the duration of the time period from the start time.
End Time = Start Time + Time Period
 Fixed time period
In a Fixed trend period, the start time is initially the current time. The start time of a trend
period does not change automatically and can be specified by a script using the StartTime
property.
The end time of a Fixed trend period is set by the duration of the trend from the specified
start time of the period. The EndTime property is read only.
End Time = Start Time + Time Period

Understanding Trend Pen Historical Data Retrieval


When a Trend Pen first loads into WindowViewer it begins plotting in real-time. Simultaneously, if
configured for historical retrieval it will backfill the Trend Pen with historical data.
The following procedure shows the steps to configure a Trend Pen. Typically, configuring a Trend
Pen includes several steps to place the Trend Pen next to a meter symbol to visually indicate the
Trend Pen plot shows the changes in the symbol’s process value over time.
To configure Trend Pen
1. Click Trend Pen from the Graphic Toolbox.
The cursor changes to a cross hair when placed over the Symbol Editor canvas area.
2. Place the cursor over the canvas at the position you want to set as a horizontal boundary of
the Trend Pen plot.
3. Pressing the left mouse button, drag the cursor to create a rectangle.
The horizontal and vertical boundaries of the Trend Pen graphic rectangle represent the
drawing area of Trend Pen plot during run time. The horizontal axis of the graphic rectangle
represents the time period of the trend. The vertical axis represents the range of the trend’s
possible values.

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

5. Enter a reference in the Reference field.


The reference is the data source that appears as the value shown by the trend, which can be
an external reference like an object’s attribute, an InTouch analog tag value, or a custom
property. Constants and expressions are not allowed.
6. Select Auto-Detect or Expression for the method to identify the location of the Historian.
Auto-Detect
The Historian server is auto-detected from the AppEngine on which the reference attribute is
running. For example, if the Reference field is set to UDO.UDA1, then Auto-Detect is set to
the Historian server name configured for the AppEngine on which UDO is running.
Expression
When an expression or reference is entered in the Server Name field, the Trend Pen connects
to the specified Historian Server.
The icon to the left of the Server Name field toggles input to the field as an expression or
Static Text mode.
A Trend Pen only shows live data if the Server Name field is left blank in Expression mode.
7. Select Moving or Fixed as the type of trend time period.
Moving
The start time of a trend period is the current time. The end time is the duration of the time
period from the start time. The start time for the next period is set to the end time of the
previous trend period.
Fixed
In a Fixed trend time period, the StartTime and EndTime properties do not change
automatically. The start time of a trend period is the current time initially. The StartTime
property can be changed by a script.
The EndTime property of a Fixed trend period is read only. The end time of a trend period is
the duration of the trend from the specified start time of the period.
8. Set the X-axis time period of the trend line in the Duration (Minutes) field.
The trend time period can be specified as a constant, an external reference, an expression, or
custom property. If a floating point number is entered, the period is rounded up to the nearest
minute.
The minimum trend period is 1 minute and the maximum period is 10080 minutes (1week).

InTouch HMI 2017 Update 3


6-72 Module 6 – Data Logging and Trending

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.

Changing Trend Pen Properties During Run Time


A Trend Pen contains a collection of properties whose values can be modified during run time to
change the visual and functional characteristics of a trend.

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.

InTouch HMI 2017 Update 3


6-74 Module 6 – Data Logging and Trending

Start Time = End Time - Duration

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

InTouch HMI 2017 Update 3


6-76 Module 6 – Data Logging and Trending

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

Lab 18 – Trending with Trend Pen

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

InTouch HMI 2017 Update 3


6-78 Module 6 – Data Logging and Trending

Prepare the Mixer Symbol for the Trend Pen


The following steps are common to all students. In this part, you will modify the Mixer symbol to
create room for the Trend Pen.
1. In WindowMaker, ArchestrA Graphic Toolbox, open the Mixer symbol for editing.
2. In the ArchestrA Symbol Editor, Elements list, select Tank.
3. In the Properties pane, adjust the Width property to 500.

4. Ensure Snap to Grid is enabled.

Wonderware Training
Lab 18 – Trending with Trend Pen 6-79

5. On the canvas, select the Temperature element.


6. Move the Temperature element to the right side of the tank.

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.

InTouch HMI 2017 Update 3


6-80 Module 6 – Data Logging and Trending

8. With the Temperature, Level and Agitator elements selected, on the toolbar, click Make
Horizontal Spacing Equal.

9. Right-click the canvas and click Select All.


10. With all elements selected, use the arrow keys to move the graphics to the upper left corner of
the canvas, leaving one blank grid space on the left and top of the canvas.

Wonderware Training
Lab 18 – Trending with Trend Pen 6-81

11. Click on a blank space on the canvas to select the canvas.


12. In the Properties pane, Size property, select Fixed.

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.

InTouch HMI 2017 Update 3


6-82 Module 6 – Data Logging and Trending

Option 1: Add a Trend Pen to the Temperature Meter for InTouch


History
This option is for students who have completed Lab 14, “Logging Historical Data Using InTouch
History”. Next, you will add a Trend Pen to compliment the Temperature meter. The Trend Pen will
be configured to backfill using InTouch historical data from LGH files.
16. In WindowMaker, in the ArchestrA Graphic Toolbox, open the Mixer symbol for editing.
17. Right-click the canvas and select Custom Properties and create the following:

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%.

19. In the Tools pane, click Trend Pen.

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.

InTouch HMI 2017 Update 3


6-84 Module 6 – Data Logging and Trending

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

22. Click OK to close the Edit Animations dialog box.

Wonderware Training
Lab 18 – Trending with Trend Pen 6-85

23. Name the Trend Pen element TempPen.


24. With TempPen selected, in the Properties pane, set the Width to 150 and Height to 130.
25. Align TempPen with the Temperature element as shown.

Note: If necessary, disable Snap to Grid to accurately align the Trend Pen.

26. In the toolbar, click Zoom to Normal.

27. Save and close the Mixer symbol.

InTouch HMI 2017 Update 3


6-86 Module 6 – Data Logging and Trending

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.

29. Click Development!.

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%.

33. In the Tools pane, click Trend Pen.

InTouch HMI 2017 Update 3


6-88 Module 6 – Data Logging and Trending

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

36. Click OK to close the Edit Animations dialog box.

InTouch HMI 2017 Update 3


6-90 Module 6 – Data Logging and Trending

37. Name the Trend Pen element LevelPen.


38. With LevelPen selected, in the Properties pane, set the Width to 130 and Height to 130.
39. Align LevelPen with the Level element as shown.

40. In the toolbar, click Zoom to Normal.

41. Save and close the Mixer symbol.

Next, you will test the Trend Pen in runtime.


42. In WindowMaker, click Runtime.
The trend will backfill and display the last five minutes of data, and then continuously plot in
real time.

43. Click Development!.

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

Section 1 – Introduction to InTouch QuickScript

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.

InTouch HMI 2017 Update 3


7-4 Module 7 – Introduction to QuickScript

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

Data Change Scripts


Data Change scripts execute each time their specified tagname or tagname.field in the
Tagname[.field] field changes. A tagname must change by an amount greater than the deadband
specified in its Tagname Dictionary definition. For example, a Data Change script tied to an I/O
real temperature, may cause the Data Change script to execute thousands of times an hour, even
for unintended noise coming from the I/O source.
Data Change scripts are best used for monitoring events or less frequently changing data. For
example, a Data Change script tied to an I/O Discrete tag that monitors the start cycle on a blast
freezer, and would change parameters for the process automatically when the blast freezer starts.
Or a Data Change script monitors an operator initiated emergency shutdown switch and the script
clears the operational state of several key process tags or changes some animation or data
presentation behaviors based on the emergency shutdown.

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.

Order of Operations for Key Scripts


Action scripts can have a key bound to the execution of the action script. Action scripts are local
scripts which is addressed in the following section. Because key bindings can existing in both Key
scripts and Action scripts InTouch must manage the order of operations when the same keystroke
is used in both an Action script and a Key script.
For example, the F1 key is bound to an action script on a currently open window. Additionally, the
F1 key is bound to a Key script which is handled globally by the InTouch application. InTouch
prioritizes the Action script on the window over the global Key script. As long as the window with
the Action script is open, pressing F1 will cause the Action script to execute, not the Key script
associated with F1. As soon as the window closes, F1 execute the Key script. If the F1 key was
linked to Help documentation, you would see local, contextual Help documentation for the
currently opened window. If no windows were opened, you would see generalized Help
documentation for the entire application.

InTouch HMI 2017 Update 3


7-6 Module 7 – Introduction to QuickScript

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.

InTouch HMI 2017 Update 3


7-8 Module 7 – Introduction to QuickScript

Working with the Script Editor


Use the script editor to create and edit scripts within InTouch WindowMaker. The following
example is for an Application script. Each type of script has its own version of the script dialog box,
with options and selections that are unique to that type of script. The title bar of the editor identifies
which type of script you are working with.

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

Color Indicators for InTouch Script Elements


The InTouch script editor uses different text colors to identify different script elements. The
following table shows the text colors associated with script elements.

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.

Accepting Autocomplete Suggestions


Insert an item at the editor caret from the autocomplete list box without an end line or tab
appended by doing one of the following:
 Double-click the item
 Highlight (select) the item and press the Enter key or the Tab key
 Type a space, period, comma, open or closed parenthesis, or other punctuation used in
the programming language (: ; [ ] = < > - + / *), and the item highlighted in the
autocomplete list box will be inserted at the editor caret with the additional character
appended.

InTouch HMI 2017 Update 3


7-10 Module 7 – Introduction to QuickScript

Multi-level Undo and Redo in InTouch Scripting


You can selectively undo a history of changes to your script. The number of changes that can be
undone is limited only by the amount of available memory.
 Use main menu options Edit, then Undo or Ctrl+Z to undo edits. You can also use context
menu options to undo and redo.
 Use main menu options Edit, then Redo or Ctrl+Y to redo edits. You can also use context
menu options to undo and redo.
An undone change can be redone. Redo mirrors undo changes. A single undo typically is
comprised of sequences of typing or deleting, which can be interrupted by interaction with an
autocomplete list or by moving the cursor with the mouse, or by clicking elsewhere in the script.
All pending undo and redo actions will be lost when you save your script, switch to another script,
or switch condition type.

Visual Indication of InTouch Script Errors


Errors in InTouch script text are marked with a red "squiggly" underline. Hovering over the error
with the mouse cursor will display the error message as a tooltip. The tooltip error message
provides the same information as the message shown when clicking Validate. In some cases,
more than one error will be underlined.

Script Line Numbers


The script editor displays line numbers in the left margin.
 Line numbers of up to four digits will display when the script editor is not zoomed
 Use the right-click context menu Go To function to go to a specific line in the script
 Delete the current line of text by pressing Ctrl+L
 You can select and drag a line of text to a different line

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.

Find and Replace


The InTouch script editor provides customizable find and replace functionality.

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.

IF THEN ELSE ENDIF Statement


Branching or decision making in InTouch scripting is handled via conditions (also named condition
expressions) using a series of keywords, namely: IF, THEN, and ENDIF. Optionally, an ELSE
keyword may be used between THEN and ENDIF. These keywords are used to conditionally
execute a choice between two outcomes (TRUE or FALSE). The choice is made based on the
evaluation of a condition or expression placed directly between the keyword IF and the keyword
THEN in the sequence.
For example,
IF MyTagname > 8.9 THEN
The portion of this example between the keywords, MyTagname > 8.9 is evaluated by checking if
the part on the left side of the greater than symbol (>) is a larger quantity than the part on the right
side. Let’s say MyTagname contained a value of 10, the conditional expression would be TRUE.
The portion of the script following the THEN keyword is executed.
These keywords must be spelled as shown in separate words; however, they are not case
sensitive. Any of the following are the same to the InTouch script editor: IF, iF, If, and if. However,
because these are reserved keywords used for scripting, an InTouch application designer is
restricted from creating an InTouch tagname using any of these keywords. Each IF must have a
matching THEN and ENDIF; followed by a semicolon. Any statements placed after the THEN also
require a semicolon at the end of each statement.

InTouch HMI 2017 Update 3


7-12 Module 7 – Introduction to QuickScript

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:

< Less than


> Greater than
<= Less than or equal to
>= Greater than or equal to
== Equivalency ("is equivalent to")
<> Not equal to
NOT Not equal to
AND Combines logical expressions
OR Either logical expression is evaluated separately

Below are some examples of complex scripts using comparison operators.


IF THEN statement:
IF EmergencyShutdownSwitch_Reactor04 <> 0 THEN
SafetyShutdownProcedure_Reactor04 = 1;
ENDIF;
In the above example, if EmergencyShutdownSwitch_Reactor04 was an I/O Discrete tag which is
set to 1 whenever an operator or system in the field triggers a shutdown of Reactor 04, this script
will take action by setting a flag named SafetyShutdownProcedure_Reactor04 to a value of 1.
IF THEN statement with ELSE clause:
IF Temperature > (TemperatureSetpoint + TemperatureDeadband) THEN
Cooling = 1;
ELSE
Cooling = 0;
ENDIF;
In the above example, Cooling is shutdown when the Temperature is below the setpoint plus a
deadband.

Wonderware Training
Section 1 – Introduction to InTouch QuickScript 7-13

Using Program Loops


Loops allow you to execute a section of code repeatedly. The InTouch HMI only supports FOR
loops. A FOR loop works by monitoring the value of a numeric loop variable that is incremented or
decremented with each loop iteration. The loop is executed until the value of the loop variable
reaches a fixed limit.

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.

Caution: Loop execution affects other run-time processes.

InTouch HMI 2017 Update 3


7-14 Module 7 – Introduction to QuickScript

Forcing the End of a Loop


You can exit a loop at any time by calling the following statement:
EXIT FOR;
This statement causes script execution to continue at the statement immediately following the loop
NEXT statement.

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;

Effect of Loops on Other Run-Time Processes


While a FOR loop is executing, all other run-time processes in WindowViewer are paused. This
includes the following areas:
 Screen updates (animation links, value displays, trends, etc.). This means that you cannot
use FOR loops to animate objects, because no movement will occur until after the loop
has completed.
 I/O communications. For example, if you modify the value of an I/O tag in a FOR loop, only
the value after the final iteration is written to the I/O device.
 Other scripts, including asynchronous QuickFunctions.
You can avoid pausing other run-time processes by placing the FOR loop in an asynchronous
QuickFunction.

Time Limit for Loop Execution


To avoid infinite loops, there is a time limit during which FOR loops must complete execution. If a
loop does not complete execution after this time span, WindowViewer automatically terminates it
and writes a message about the termination to the Log Viewer.
The default time limit is 5 seconds. You can customize it by adding the following line to the
intouch.ini file in your application directory:
LoopTimeout=x
Replace x with the time limit in seconds.

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;

InTouch HMI 2017 Update 3


7-16 Module 7 – Introduction to QuickScript

Wonderware Training
Lab 19 – Opening an Application with QuickScript 7-17

Lab 19 – Opening an Application with


QuickScript

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

InTouch HMI 2017 Update 3


7-18 Module 7 – Introduction to QuickScript

Create a Key Script to Open an Application


In the following steps, you will create a Key script that opens the calculator each time a key is
pressed on the keyboard.
1. Close WindowViewer.
2. In the WindowMaker Scripts pane, double-click Key.

The Key Scripts dialog box appears.

Wonderware Training
Lab 19 – Opening an Application with QuickScript 7-19

3. In the Key area, click the Key button.

The Choose key dialog box appears.

4. In the Chose key dialog box, click F12.

In the Key area, F12 appears.

InTouch HMI 2017 Update 3


7-20 Module 7 – Introduction to QuickScript

5. On the Condition Type drop-down list, ensure On Key Down is selected.

6. On the right side of the Key Scripts dialog box, click System.

The Choose Function dialog box appears.


7. Click StartApp.

Wonderware Training
Lab 19 – Opening an Application with QuickScript 7-21

StartApp is inserted into the body of the script.

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”

InTouch HMI 2017 Update 3


7-22 Module 7 – Introduction to QuickScript

9. On the right side of the Key Scripts dialog box, click Validate.

A warning message appears stating Expecting semicolon.

10. Click OK.


Next, you will correct the script to remove the warning.
11. In the body of the script, at the end of Line 1, enter ;.
The line of script now looks like the following image.
StartApp “calc”;

12. Click Validate.


No error message appears.
13. Click OK to save and close the Key Scripts dialog box.

Note: The OK button also validates the script.

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.

InTouch HMI 2017 Update 3


7-24 Module 7 – Introduction to QuickScript

16. Click the WindowViewer title bar.

WindowViewer now becomes the active Windows application and the calculator is hidden
behind WindowViewer.

17. Press F12.


A new instance of the calculator opens. Both instances can be seen on the task bar.

18. Close all instances of the calculator.

Wonderware Training
Lab 19 – Opening an Application with QuickScript 7-25

Modify the Key Script


Next, you will modify the Key script to prevent new instances of the calculator from opening each
time the F12 key is pressed.
19. Click Development!.
20. In the WindowMaker Scripts pane, double-click Key.
The Key Scripts dialog box appears.
21. Clear the body of the script.
22. In Line 1, enter IF, and press the space bar.

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.

25. In Line 1, replace AppTitle with “Calculator”.

26. At the end of Line 1, delete ; and enter ==1 THEN.


27. Press Enter to add a new line.

InTouch HMI 2017 Update 3


7-26 Module 7 – Introduction to QuickScript

28. In Line 2, press the Tab key.


The Tab key is used as cosmetic white space for readability. It highlights the command that will
execute when the IF statement is True.
29. Click System, and select ActivateApp.
The ActivateApp function is inserted in Line 2.

30. At the end of Line 2, enter a space, and enter “Calculator”;.


The text “Calculator” is marked with a red squiggly line, indicating an error. This is expected
because the ActivateApp function is not validated until the script is saved.
31. Press Enter to add a new line.
32. Press the Backspace key to delete the automatic tab.

33. In Line 3, enter ELSE.


34. Press Enter to add a new line.

35. In Line 4, press the Tab key.


36. Click System, and select StartApp.
The StartApp function is inserted into Line 4.
37. At the end of Line 4, enter a space, and enter “calc”;.
38. Press Enter to add a new line.

Wonderware Training
Lab 19 – Opening an Application with QuickScript 7-27

39. Press the Backspace key to delete the automatic tab.


40. In Line 5, enter ENDIF;.

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.

41. Click Validate.


No warning message appears.
42. Click OK.
43. Close WindowViewer.

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!.

InTouch HMI 2017 Update 3


7-28 Module 7 – Introduction to QuickScript

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

Section 1 – ArchestrA Symbol QuickScript.NET


This section will provide an overview of ArchestrA Symbol QuickScript.NET, and describe the
features and functions that are unique to each script type. This section will also explain the
QuickScript Editor.

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.

InTouch HMI 2017 Update 3


8-4 Module 8 – Introduction to ArchestrA Symbol QuickScript .NET

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.

InTouch HMI 2017 Update 3


8-6 Module 8 – Introduction to ArchestrA Symbol QuickScript .NET

ArchestrA Symbol QuickScript.NET Editor


Use the script editor to create and edit scripts within the Symbol Editor. Each type of script has its
own version of the script editor, with options and selections that are unique to that type of 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

Color Indicators for InTouch Script Elements


The script editor uses different text colors to identify different script elements. The following table
shows the text colors associated with script elements.

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.

Accepting Autocomplete Suggestions


Insert an item at the editor caret from the autocomplete list box without an end line or tab
appended by doing one of the following:
 Double-click the item
 Highlight (select) the item and press the Enter key or the Tab key
 Type a space, period, comma, open or closed parenthesis, or other punctuation used in
the programming language (: ; [ ] = < > - + / *), and the item highlighted in the
autocomplete list box will be inserted at the editor caret with the additional character
appended.

InTouch HMI 2017 Update 3


8-8 Module 8 – Introduction to ArchestrA Symbol QuickScript .NET

Multi-level Undo and Redo in Scripting


You can selectively undo a history of changes to your script. The number of changes that can be
undone is limited only by the amount of available memory.
 Use main menu options Edit, then Undo or Ctrl+Z to undo edits. You can also use context
menu options to undo and redo.
 Use main menu options Edit, then Redo or Ctrl+Y to redo edits. You can also use context
menu options to undo and redo.
An undone change can be redone. Redo mirrors undo changes. A single undo typically is
comprised of sequences of typing or deleting, which can be interrupted by interaction with an
autocomplete list or by moving the cursor with the mouse, or by clicking elsewhere in the script.
All pending undo and redo actions will be lost when you save your script, switch to another script,
or switch condition type.

Visual Indication of Errors in Script Text


Errors in InTouch script text are marked with a red "squiggly" underline. Hovering over the error
with the mouse cursor will display the error message as a tooltip. The tooltip error message
provides the same information as the message shown when clicking Validate. In some cases,
more than one error will be underlined.

Script Line Numbers


The script editor displays line numbers in the left margin.
 Line numbers of up to four digits will display when the script editor is not zoomed
 Use the right-click context menu Go To function to go to a specific line in the script
 You can select and drag a line of text to a different line

Find and Replace


The script editor provides customizable find and replace functionality.

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.”

InTouch HMI 2017 Update 3


8-10 Module 8 – Introduction to ArchestrA Symbol QuickScript .NET

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}

Handling White Space


Spaces and indentation can be used to improve readability, except that at least one space must
appear between adjacent identifiers, and spaces and line breaks cannot appear within identifiers
and numbers. Individual statements are distinguished by a semicolon that marks the end of a
statement. White space rules apply for space and indention. Indent using spaces, or the TAB key.
Individual statements are indicated by a semicolon marking the end of the statement.

IF THEN ELSE ENDIF Statement


Branching or decision making in scripting is handled via conditions (also named condition
expressions) using a series of keywords, namely: IF, THEN, and ENDIF. Optionally, an ELSE
keyword may be used between THEN and ENDIF. These keywords are used to conditionally
execute a choice between two outcomes (TRUE or FALSE). The choice is made based on the
evaluation of a condition or expression placed directly between the keyword IF and the keyword
THEN in the sequence.
For example,
IF MyTagname > 8.9 THEN
The portion of this example between the keywords, MyTagname > 8.9 is evaluated by checking if
the part on the left side of the greater than symbol (>) is a larger quantity than the part on the right
side. Let’s say MyTagname contained a value of 10, the conditional expression would be TRUE.
The portion of the script following the THEN keyword is executed.
These keywords must be spelled as shown in separate words; however, they are not case
sensitive. Any of the following are the same to the script editor: IF, iF, If, and if. However, because
these are reserved keywords used for scripting, an InTouch application designer is restricted from
creating an InTouch tagname using any of these keywords. Each IF must have a matching THEN
and ENDIF; followed by a semicolon. Any statements placed after the THEN also require a
semicolon at the end of each statement.
The simplest form of this conditional branching functionality is illustrated by the following example:
IF UnauthorizedAccess == 1 THEN
SecurityAlert = True;
ENDIF;

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:

< Less than


> Greater than
<= Less than or equal to
>= Greater than or equal to
== Equivalency ("is equivalent to")
<> Not equal to
NOT Not equal to
AND Combines logical expressions
OR Either logical expression is evaluated separately

Below are some examples of complex scripts using comparison operators.


IF THEN statement:
IF EmergencyShutdownSwitch_Reactor04 <> 0 THEN
SafetyShutdownProcedure_Reactor04 = 1;
ENDIF;
In the above example, if EmergencyShutdownSwitch_Reactor04 was a Boolean custom property
which is set to 1 whenever an operator or system in the field triggers a shutdown of Reactor 04,
this script will take action by setting a flag named SafetyShutdownProcedure_Reactor04 to a value
of 1.

InTouch HMI 2017 Update 3


8-12 Module 8 – Introduction to ArchestrA Symbol QuickScript .NET

FOR … TO … STEP … NEXT Loop


FOR-NEXT performs a function (or set of functions) within a script several times during a single
execution of a script. The general format of the FOR-NEXT loop is as follows:
FOR <analog_var> = <start_expression> TO <end_expression> [STEP
<change_expression>];
[statements];
[EXIT FOR;];
[statements];
NEXT;
Where:
 analog_var is a variable of type Integer, Float, Real, or Double.
 start_expression is a valid expression to initialize analog_var to a value for execution of
the loop.
 end_expression is a valid expression. If analog_var is greater than end_expression,
execution of the script jumps to the statement immediately following the NEXT statement.
This holds true if loop is incrementing up, otherwise, if loop is decrementing, loop
termination occurs if analog_var is less than end_expression.
 change_expression is an expression that defines the increment or decrement value of
analog_var after execution of the NEXT statement. The change_expression can be either
positive or negative.
 If change_expression is positive, start_expression must be less than or equal to
end_expression or the statements in the loop do not execute.
 If change_expression is negative, start_expression must be greater than or equal to
end_expression for the body of the loop to be executed.
 If STEP is not set, then change_expression defaults to 1 for increasing increments, and
defaults to -1 for decreasing increments.
Exit the loop from within the body of the loop with the EXIT FOR statement.
The FOR loop is executed as follows:
1. analog_var is set equal to start_expression.
2. If change_expression is positive, the system tests to see if analog_var is greater than
end_expression. If so, the loop exits. If change_expression is negative, the system tests to
see if analog_var is less than end_expression. If so, program execution exits the loop.
3. The statements in the body of the loop are executed. The loop can potentially be exited via the
EXIT FOR statement.
4. analog_var is incremented by 1,-1, or by change_expression if it is specified.
5. Steps 2 through 4 are repeated.

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

FOR EACH … IN … NEXT


FOR EACH loops can be used only with collections exposed by OLE Automation servers. A FOR-
EACH loop performs a function (or set of functions) within a script several times during a single
execution of a script. The general format of the FOR-EACH loop is as follows:
FOR EACH <object_variable> IN <collection_object >
[statements];
[EXIT FOR;];
[statements];
NEXT;
Where:
 object_variable is a dimmed variable.
 collection_object is a variable holding a collection object.
As in the case of the FOR … TO loop, it is possible to exit the execution of the loop through the
statement EXIT FOR from within the loop.

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.

InTouch HMI 2017 Update 3


8-14 Module 8 – Introduction to ArchestrA Symbol QuickScript .NET

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.

About the Show/Hide Graphic Functions


The Show/Hide Graphic script functions allow you to write ArchestrA graphic scripts to display a
symbol as a popup window and close the popup window.
The Show/Hide Graphic script functions are in addition to the Show/Hide Symbol animation
feature, which allows you to display a symbol as a popup window through symbol animation. The
Show/Hide Symbol animation feature remains unchanged. You can use Show/Hide Symbol
animation and the Show/Hide Graphic script functions together
Like the Show/Hide Symbol animation feature, you can control the properties of the symbol
through the Show Graphic script function.
You can configure the script to specify:
 Which symbol will appear as the popup window
 Whether the window will have a title bar
 The initial position of the popup window
 Whether the window can be resized
 Whether the window will be modal or modeless
 The relative position of the popup window
 Passing the OwningObject to the symbol to display
 Values of the custom properties of the symbol

Configuring the Show/Hide Graphic Script Functions


When configuring this feature, include a script that contains the ShowGraphic script function to
display a symbol as a popup window at runtime. You can also include a script that contains the
HideGraphic script function.
The HideGraphic script function allows the closing of any ArchestrA symbol displayed through the
ShowGraphic script function.

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.

Runtime Behavior of the Show/Hide Graphic Functions


The Show/Hide Graphic script functions exhibit the following behavior:
 The graphic, configured with the ShowGraphic script function, behaves like a
ShowSymbol animation popup window, rather than an InTouch popup window.
 You can configure a symbol with both the ShowSymbol animation and ShowGraphic
together. If you run both at runtime, two popup windows open, displaying the same or
different symbols. The two popup windows are independent of each other.
 You can open and close the graphic from across symbols and across InTouch windows.
You can manage the graphic across the entire InTouch application.
 Unlike ShowSymbol animation, there is no parent/child relationship between the window
that opened the graphic and the graphic opened by the ShowGraphic() script function.
 You cannot use the Close Window dialog box of InTouch WindowViewer to close the
popup windows displayed by the ShowGraphic script function.
 Any graphic displayed by the ShowGraphic script function or ShowSymbol animation
always remains in front of InTouch windows, except InTouch popup windows. Even if you
click an InTouch window, the window remains behind these graphics.
 Enabling in-memory graphics caching in WindowViewer memory properties will keep
ShowGraphic and ShowSymbol animation popup symbols cached in memory. The system
tracks the order in which graphics are closed in order to determine their age. If a user-
defined in-memory limit is exceeded, the system automatically removes the oldest popup
symbols in the in-memory graphics cache, except those defined in high-priority windows.
If you display a symbol with the ShowGraphic script function or with ShowSymbol
animation, WindowViewer will perform a memory health check.

InTouch HMI 2017 Update 3


8-16 Module 8 – Introduction to ArchestrA Symbol QuickScript .NET

Behavior of ShowGraphic Windows with the Same Identity


ShowGraphic popup windows attempting to open a popup window with the same Identity exhibit
the following behavior with the predefined scripts OnHide, OnShow, and WhileShowing:
 A ShowGraphic script function within an OnShow script will be blocked, if a ShowGraphic
popup window with the same Identity is already displayed.
 A ShowGraphic script function within an WhileShowing script will be blocked, if a
ShowGraphic popup window with the same Identity is already displayed.
 A ShowGraphic script function within an OnHide script will be blocked, if a ShowGraphic
popup window with the same Identity is already displayed.
No error or warning messages will appear in the logger, when script execution is blocked as
described.
With the Graphic cache memory option enabled, calling ShowGraphic popup windows with the
same identity name, if the symbol is modal to the modal symbol behind it, calling the ShowGraphic
script function cannot change this symbol to be modeless to the current modal symbol.

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

Section 2 – ShowGraphic() and InTouch Windows


This section will explain a scalable method to navigate an InTouch application.

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.

Configuring Combo Box Controls


You can use one of the following combo box control types:
 Simple: No drop-down list; allows entry of values
 DropDown: Has a drop-down list; allows entry of values
 DropDownList: Has a drop-down list; does not allow entry of any value
You can use Combo Box controls to select an option from a foldable list. You can configure:
 Drop-down type of combo box control
 Width of the drop-down list
 Maximum number of items to appear in the drop-down list
You can also use properties that are specific to the Combo Box control in scripting. At runtime, you
can use a script , view, and modify the items in the Combo Box control; to save a list of items in the
Combo Box control to obtain the value of the currently selected item; to delete items from the list;
and to load the list into the Combo Box from a file.

InTouch HMI 2017 Update 3


8-18 Module 8 – Introduction to ArchestrA Symbol QuickScript .NET

Using a Drop-Down List to Navigate


A Menu window in your application can display a drop-down list containing window names which
can be selected by the user to navigate to the selected window in runtime. A Data Change script
monitors the selected window and automatically opens the window that has been selected. The
symbol containing the drop-down list must be linked to the Data Change script using a tag.
Because the drop-down list contains names of windows the tag that is selected must use a
message data type to store the text names of windows.

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.

Using the Identity Property in the ShowGraphic() Function


The Identity must be unique across the InTouch application. If you want to add the HideGraphic
script function, you must use the same Identity as a parameter that you have used in the
ShowGraphic script. The HideSelf script function does not have any parameters.

Simple use of ShowGraphic


The Identity property of the basic ShowGraphic script function, using the syntax
“InTouch:Window”, supports opening InTouch native windows. The GraphicName property
supports calling a symbol when the InTouch:Window syntax is used. Only three lines of script are
required for this simple use of ShowGraphic.

Advanced use of ShowGraphic


ShowGraphic supports opening symbols in runtime and dynamically linking tag references to the
symbol that appears in the popup window. Opening symbols in popup windows requires
configuring several properties, setting custom property-value pairs, and identifying the size and
location of the popup window. A minimum script to support this advanced use of ShowGraphic can
easily reach 20 or more lines of script.
ShowGraphic popup windows attempting to open a popup window with the same Identity exhibit
the following behavior with the predefined scripts OnHide, OnShow, and WhileShowing:
 A ShowGraphic function within an OnShow script will be blocked if a ShowGraphic popup
window with the same Identity is already displayed.
 A ShowGraphic function within a WhileShowing script will be blocked if a ShowGraphic
popup window with the same Identity is already displayed.
 A ShowGraphic function within an OnHide script will be blocked if a ShowGraphic popup
window with the same Identity is already displayed. No error or warning messages will
appear in the logger when script execution is blocked as described. With the Graphic
Cache memory option enabled, calling ShowGraphic popup windows with the same
identity name, if the symbol is modal to the modal symbol behind it, calling the
ShowGraphic function cannot change this symbol to be modeless to the current modal
symbol.

Use of String Concatenation Concepts in Scripting


String concatenation is a script operation that joins two strings together to form a single string.
When used in InTouch scripting, and ArchestrA Symbol scripting, there are three building blocks
that can be used to construct a string. These are an InTouch Message tag (string custom
property), a string literal (any text between double quotes), and a script function that returns a
string value (for example, the Text function).
An example of string concatenation is as follows.
$DateString + Text(Mixer100_Level_PV, “#”) + “ is the level value.”;
In the example $DateString is a system message tag, which contains the current date. Followed
by the text function, which converts the numerical tag Mixer100_Level_PV to a string and finally

InTouch HMI 2017 Update 3


8-20 Module 8 – Introduction to ArchestrA Symbol QuickScript .NET

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

Lab 20 – Creating a Scalable Window


Navigation Control

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

InTouch HMI 2017 Update 3


8-22 Module 8 – Introduction to ArchestrA Symbol QuickScript .NET

Build the Symbol


In the following steps, you will create the Nav symbol.
1. In the WindowMaker Training toolset, create a symbol named Nav, and open it for editing.
2. On the canvas, add a custom property named WindowName.
3. Using the Data Type drop-down list, select String.
4. In the Visibility area, click Private.

5. Click OK.

6. In the Tools pane, select the Combo Box tool.

7. On the canvas, draw a combo box rectangle.

Wonderware Training
Lab 20 – Creating a Scalable Window Navigation Control 8-23

8. In the Properties pane, name the combo box ProductionList.


9. Adjust the Width to 200.
ProductionList will look similar to the following image.

10. Double-click ProductionList, and in the Reference field, enter WindowName.


11. Check the Use Values as Captions check box.

InTouch HMI 2017 Update 3


8-24 Module 8 – Introduction to ArchestrA Symbol QuickScript .NET

12. Click the Add a row [Insert] button.


13. In the Static Values and Captions area, Value column, enter the following values:
 Mixer
 KPI
 Current Alarms
 Historical Alarms and Events

14. On the Type drop-down list, select DropDown.

15. Click OK.

Wonderware Training
Lab 20 – Creating a Scalable Window Navigation Control 8-25

Add a Named Script with a Data Change Trigger


Next, you will create a Named script using a Data Change trigger. The script will include a
ShowGraphic script function which will open native InTouch windows when the user selects a
window name.
16. On the canvas, right-click, and select Scripts.
The Edit Scripts dialog box appears.

17. Click Add Script.

18. Name the script OpenWindow.


19. In the OpenWindow animations pane, Expression field, enter WindowName.

InTouch HMI 2017 Update 3


8-26 Module 8 – Introduction to ArchestrA Symbol QuickScript .NET

20. On the Trigger drop-down list, select DataChange.


21. Click Display Script Function Browser.

The Script Function Browser dialog box appears.

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.

23. Click OK.


Four lines of script are pasted into the body of the script.

InTouch HMI 2017 Update 3


8-28 Module 8 – Introduction to ArchestrA Symbol QuickScript .NET

24. In the script body, delete Line 3.


The script now has three lines.

25. In Line 2, between the quotes, delete the text <Identity>.


26. At the cursor position, enter InTouch:.

27. In Line 2, place the cursor between the quote and semicolon, and enter + WindowName.

28. Click OK to validate, save, and close the script.


29. Save and close Nav.
30. Embed Nav in the Menu window to the right of the navigation buttons.

Wonderware Training
Lab 20 – Creating a Scalable Window Navigation Control 8-29

Test What You Have Built


Finally, you will test scalable window navigation in runtime.
31. Click Runtime.
32. Close the Mixer window.

33. On the Nav symbol drop-down list, select Mixer.


The Mixer window appears.

34. Test additional navigation, as desired.


35. Click Development.

InTouch HMI 2017 Update 3


8-30 Module 8 – Introduction to ArchestrA Symbol QuickScript .NET

Wonderware Training
Section 3 – ShowGraphic and ArchestrA Symbols 8-31

Section 3 – ShowGraphic and ArchestrA Symbols

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.

Runtime Behavior of the Show/Hide Graphic Functions


The Show/Hide Graphic script functions exhibit the following behavior:
 The graphic, configured with the ShowGraphic script function, behaves like a
ShowSymbol animation popup window, rather than an InTouch popup window.
 You can configure a symbol with both the ShowAnimation and ShowGraphic scripts
together. If you execute the two scripts at runtime, two popup windows open, displaying
the same or different symbols. The two popup windows are independent of each other.
 You can open and close the graphic from across symbols and across InTouch windows.
You can manage the graphic across the entire InTouch application.
 Unlike ShowSymbol animation, there is no parent/child relationship between the window
that launched the graphic and the graphic launched by the ShowGraphic() script function.
 You cannot use the Close Window dialog box of InTouch WindowViewer to close the
popup windows displayed by the ShowGraphic script function.
 Any graphic displayed by the ShowGraphic script function or ShowSymbol animation
always remains in front of InTouch windows, except InTouch popup windows. Even if you
click an InTouch window, the window remains behind these graphics.
 Enabling in-memory graphics caching in WindowViewer memory properties will keep
ShowGraphic and ShowSymbol animation popup symbols cached in memory. The system
tracks the order in which graphics are closed in order to determine their age. If a user-
defined in-memory limit is exceeded, the system automatically removes the oldest popup
symbols in the in-memory graphics cache except those defined in high-priority windows. If
you display a symbol with the ShowGraphic script function or with ShowSymbol
animation, WindowViewer will perform a memory health check.

InTouch HMI 2017 Update 3


8-32 Module 8 – Introduction to ArchestrA Symbol QuickScript .NET

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.

Working with Modal Windows


The ShowGraphic script function defaults to using a modeless window type. This allows
WindowViewer to remain interactive while the popup window is on top.
If a popup window is called using the ShowGraphic() script function with the WindowType
property set to Modal, the system cannot execute the rest of the script after the
ShowGraphic(graphicInfo); line of the script. You must close the window to allow the system to
execute the rest of the script. If you want to open multiple modal popup windows, the last popup
window will override the remaining popup windows until it is closed.

Assigning Custom Property Values of a Symbol


Custom properties of a symbol can be set to values when a symbol is shown by ShowGraphic()
containing the CustomProperties property. The parameters of CustomProperties are the custom
property name, assigned value, and the IsConstant Boolean flag that indicates if the custom
property value is a constant. These parameters are specified as an array of values using the
CustomPropertyValuePair[] array. The array index starts at 1. Use a script similar to the following
to assign values to a symbol's custom properties. In this example, "i1" is string Identity and the
symbol "S1" contains custom properties CP1 and CP2. When S1 is shown during runtime, CP1 is
assigned a constant value of 20 and CP2 is assigned the current value of the reference
Pump.PV.Tagname.
Dim graphicInfo as aaGraphic.GraphicInfo;
graphicInfo.Identity = "i1";
graphicInfo.GraphicName = "S1";
graphicInfo.OwningObject = "UserDefined_001";
graphicInfo.WindowTitle = "Graphic01";
graphicInfo.Resizable = false;
graphicInfo.CustomProperties=cpValues;
Dim cpValues [2] as aaGraphic.CustomPropertyValuePair;
cpValues[1] = new aaGraphic.CustomPropertyValuePair("CP1", 20, true);
cpValues[2] = new aaGraphic.CustomPropertyValuePair("CP2","Pump.PV.TagName",
false);
ShowGraphic( graphicInfo );

Wonderware Training
Lab 21 – Building a Mixer Browser Using ShowGraphic 8-33

Lab 21 – Building a Mixer Browser Using


ShowGraphic

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

InTouch HMI 2017 Update 3


8-34 Module 8 – Introduction to ArchestrA Symbol QuickScript .NET

Create the Mixer Browser Window


In the following steps, you will create and configure a Mixer Browser window, from the
Content_Frame window template.
1. On the WindowMaker File menu, select New Window from Template.
2. In the Template Window Browser, double-click Content_Frame.
3. Change the name to Mixer Browser.

4. Click OK.
The new window is created and opened.

Wonderware Training
Lab 21 – Building a Mixer Browser Using ShowGraphic 8-35

Create the MixerBrowser Symbol


Next, you will add functionality to the Nav symbol to allow the user to select which mixer to view.
5. In WindowMaker, open the Nav symbol for editing.
6. Add a new custom property as follows:
‘Static Text’ or
Name Data Type ‘Expression or Default Value Visibility
Reference’ Mode
MixerName String Mixer100 Private

InTouch HMI 2017 Update 3


8-36 Module 8 – Introduction to ArchestrA Symbol QuickScript .NET

7. In the Elements list, double-click ProductionList to edit animations.


8. In the Static Values and Captions area, click Add a row [Insert].
9. In the new row Value column, enter Mixer Browser.

10. Click OK.


11. Duplicate the ProductionList combo box.
12. Place the duplicate below ProductionList.

13. Name the duplicate MixerList.


14. Double-click MixerList to edit animations.

Wonderware Training
Lab 21 – Building a Mixer Browser Using ShowGraphic 8-37

15. In the Reference field, enter MixerName.

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

17. Add a Visibility animation.


18. In the Visibility animations pane, Boolean field, enter WindowName == “Mixer Browser”.
19. Ensure that the Visible When Expression is area is set to True, 1, On.

20. Click OK.

InTouch HMI 2017 Update 3


8-38 Module 8 – Introduction to ArchestrA Symbol QuickScript .NET

21. On the Special menu, select Scripts.


22. Click the OpenWindow script, and modify the Expression as follows:
WindowName + MixerName
23. In the bottom-left corner, click the Hide left pane button to make the body of the script larger.

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.

Option File Name


Option 1 C:\Training\Lab 21 - Option 1
Option 2 C:\Training\Lab 21 - Option 2
Option 1 and 2 C:\Training\Lab 21 - Option 1 and 2

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.

26. Click OK to close the Edit Scripts dialog box.


27. Save and close Nav.
In WindowMaker, in the Menu window, notice your Nav symbol did not update to show two
combo boxes. The symbol will be updated automatically when you go to runtime.

InTouch HMI 2017 Update 3


8-40 Module 8 – Introduction to ArchestrA Symbol QuickScript .NET

Test What You Have Built


Next, you will test the Mixer Browser and the MixerList drop-down lists.
28. Click Runtime.
The ProductionList drop-down list appears.
29. In the Menu window, click the Nav symbol drop-down list, and select Mixer Browser.
The mixer drop-down list appears.

30. On the MixerList drop-down list, select Mixer200.


The data for Mixer200 appears in the popup window.

31. Select other mixers as desired.


32. Click Development!.

Wonderware Training
Lab 22 – Creating a Context Driven Alarm Window Using ShowGraphic 8-41

Lab 22 – Creating a Context Driven Alarm


Window Using ShowGraphic

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

InTouch HMI 2017 Update 3


8-42 Module 8 – Introduction to ArchestrA Symbol QuickScript .NET

Create an Alarm Popup Symbol


In the following steps, you will duplicate the CurrentAlarms symbol to create a PopupAlarms
symbol and then modify it to display in-context alarms when opened in runtime.
1. In WindowMaker, duplicate the CurrentAlarms symbol, and name the duplicate
PopupAlarms.
2. Double-click PopupAlarms to open it for editing.
3. On the canvas, delete all button elements.
4. Add a Custom Property as follows:

Name: Query
Data Type: String

5. On the canvas, right-click, and select Scripts.


The Edit Scripts dialog box appears.
6. In the body of the On Show script, enter: LiveAlarms.AlarmQuery = Query;

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

9. Double-click the OK button, and add an Action Scripts animation.

InTouch HMI 2017 Update 3


8-44 Module 8 – Introduction to ArchestrA Symbol QuickScript .NET

10. Configure the Action script as follows:

Trigger: On Left Click/Key/Touch Down


Body: Hideself();

Hideself( ); can be selected from the Fx browser by expanding Graphic Client.

11. Click OK.


12. Save and close PopupAlarms.
Next, you will modify the Mixer symbol to open the PopupAlarms symbol.
13. Open the Mixer symbol.
14. Add a button below Tank and configure the properties as follows:

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.

Dim graphicInfo as aaGraphic.GraphicInfo;


graphicInfo.Identity = "Alarms";
graphicInfo.GraphicName = "PopupAlarms";
graphicInfo.WindowType = aaGraphic.WindowType.Modal;
graphicInfo.WindowTitle = "Alarms for " + Tank.Label;
graphicInfo.WindowRelativePosition =
aaGraphic.WindowRelativePosition.Window;
graphicInfo.WindowLocation = aaGraphic.WindowLocation.TopLeftCorner;
Dim cpValues [1] as aaGraphic.CustomPropertyValuePair;
cpValues[1] = new aaGraphic.CustomPropertyValuePair("Query",
"\InTouch!$System!" + Tank.Label + "*", true);
graphicInfo.CustomProperties = cpValues;
ShowGraphic( graphicInfo );

17. Click OK.


18. Save and close Mixer.

InTouch HMI 2017 Update 3


8-46 Module 8 – Introduction to ArchestrA Symbol QuickScript .NET

Test What You Have Built


Finally, you will test the functionality of the Alarm popup window in runtime.
19. Click Runtime.
20. Close the Mixer Browser window.
21. Navigate to the Mixer Browser window.
22. In the Mixer Browser window, click the Alarms button to call the PopupAlarms window.
The Alarms listed are specific to the mixer selection because the mixer selection is passed to
the Alarm Query property of the Alarm Client.
23. Try to click anywhere in the application outside of the PopupAlarms window.
You cannot click behind the PopupAlarms window due to the modal window type.
24. In the PopupAlarms window, click the OK button to close the popup.
25. Browse to additional mixers, and try clicking the Alarms button.
26. Click Development!.

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

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.

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.

Different Authentication Security Modes


All types of InTouch security authenticate users during the logon process with a user name and
password combination. Each type of security provides a different mechanism to verify the user
name and password during the authentication process.
 InTouch Security
 OS Secuirty
 ArchestrA Security

InTouch HMI 2017 Update 3


9-4 Module 9 – Security

Using InTouch Security


 Applying security to your application is optional. By default, an InTouch application is not
secured. However, you can restrict which functions an operator is allowed to perform by linking
those functions to internal tags. In addition, when you establish security on your application,
audit trails can be created that associate alarms and events to the operator logged on to the
InTouch HMI.
 When you set the InTouch Security Type to InTouch, a pop-up dialog appears, suggesting
to switch to OS security mode. The dialog also appears on the launch of WindowMaker, if
InTouch security is used for the application. You can choose to turn off the notification.
 Security is based on operators authenticating themselves by entering a user name and
password to log on to an InTouch application. You must assign user name, password, and
access level for each operator.
 When you create a new application, by default, the user name is set to
 Administrator with an access level of 9999, which allows access to all security
commands. The default administrator password is wonderware. The maximum number
of characters for a password is 29.
 After you add a new user name to the security list and restart WindowMaker or
WindowViewer, the default user name is automatically reset to None with an access level
of 0, which prevents access to the Configure Users command in both WindowMaker and
WindowViewer. However, the Administrator account and password remain and can still be
used.
 After an operator logs on to the application, access to any protected function is granted
upon verification of the operator's password and access level against the value specified
for the internal security tag linked to the function.
 For Native and Modern applications, only users with Administrator privileges are allowed
to open and edit applications in InTouch WindowMaker. If a user without administrator
privileges attempts to launch InTouch WindowMaker, an error dialog box appears,
informing users that they need administrative privileges to proceed. Users without
administrative privileges can launch WindowMaker via ArchestrA IDE for Managed
applications.

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.

Using ArchestrA Security


 When you configure a node to use ArchestrA security, the InTouch HMI uses methods and
dialog boxes from Application Server for logon and logoff operations. Users are configured
on the Application Server Galaxy Repository node. For more information, see the
Application Server documentation.
 ArchestrA security enables you to easily define users and assign the operations they are
allowed to perform. Define security permissions in terms of the operations the users can
perform using automation objects. The basic approach consists of the following steps:
1. Define the security model.
2. Organize the automation objects according to the security model for protection.
3. Define the users according to the security model.
 The system administrator defines the system users by creating corresponding user
profiles. The system administrator then assigns one or more roles to each user by
selecting from a list of user roles predefined in the security model.
 If you are using InTouch with ArchestrA-based security, the maximum number of
characters for a password is 31.
 InTouchView users are normally authenticated by means of a password-based log-on.
 Information spread across modules and sections (hard to find = hard to use as reference
after class)

Comparing Authentication and Authorization


 Authentication is the process of verifying the identity of the user. Typically, operators enter
a user name and password to authenticate themselves before using an InTouch
application. All three types of security verify the user’s credentials during the logon
process as part of the authentication process.
 Authorization is the process of determining if an authenticated user has access to the
requested resources. Typically, access to InTouch functions is granted based upon the
user’s membership in a group or assigned access level.

InTouch HMI 2017 Update 3


9-6 Module 9 – Security

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.

Concepts in Securing an Application


InTouch provides a number of system tags and script functions that allow InTouch designers to
configure security and application behavior, or take specific actions based on security settings and
the current operator or operator role. Once a user is validated and logged in to the InTouch
application, the $Operator and $AccessLevel system tags contain information, as set by the
application for that operator’s user name and access level.
To log in to an InTouch application, application designers can allow users to select Special/
Security/Logon from WindowViewer, or call a script function to display a standard log in dialog
box, or present a fully customized log in window.
$AccessLevel is the tag that is normally used to secure InTouch applications. This allows
designers to categorize users based on experience or training without restricting the application to
specific users. Restricting access based on specific user names is difficult to maintain with user
changes through termination of employment, promotion to another department, failing to recertify
for certain tasks or responsibilities, and other reasons where the operator is no longer qualified.
By linking graphics, scripts, and other application features to $AccessLevel, the application
designer can restrict what operators can do within the InTouch application. For example, to disable
a pushbutton that allows an operator to navigate to a PID loop tuning window, on the button, you
can add a Disable or Visibility animation with an expression such as $AccessLevel < 5000,
where the designer has set a value of 5000 as the minimum training level and experience required
to tune a PID loop. In this example, junior operators who have not received their certifications
would be configured for access levels below 5000.

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.

Creating a Custom Security Log in Window


$OperatorEntered, $PasswordEntered, and $OperatorDomainEntered are the three tags to be
used in case a custom log in dialog box is required. The key distinction of these tags is the word
Entered implying these writable tags expect input to take action. Create a popup-type window and
set user touch links (user input string) to these tags. If the provided credentials are validated by
Microsoft, then $Operator, $AccessLevel, $OperatorDomain will update accordingly.
Designers may link the $OperatorEntered, $PasswordEntered, and $OperatorDomainEntered
system tagnames to user input objects or use them in a QuickScript to set the User Name,
Password, and Domain Name being passed to Microsoft. These are internal message (string)
type tagnames that are intended for write operation only. With OS Security, where authentication is
being done without a domain controller and is based on local machine only, authentication
$OperatorDomainEntered must be set to an empty string (blank) or using the name of the local
machine (from a cmd.exe prompt, type hostname and press Enter to get the local machine name).
After an operator logs on to the application, access to any protected function will be granted upon
verification of the operator's password, and access level against the value specified for the internal
security tagname will be linked to the function.

InTouch HMI 2017 Update 3


9-8 Module 9 – Security

System Tags in InTouch Related to Security


The following system tags are available for security.

Tagname Type Valid Values Access


$AccessLevel System Integer 0-9999 Read Only
$ChangePassword System Discrete 1 or 0 Read Write
$ConfigureUsers System Discrete 1 or 0 Read Write
$InactivityTimeout System Discrete 1 or 0 Read Write
$InactivityWarning System Discrete 1 or 0 Read Write
$Operator System Message 16-characters max Read Only
$OperatorName System Message 131-characters max Read Only
$OperatorDomain System Message 16-characters max Read Only
$OperatorDomainEntered System Message 16-characters max Write Only
$OperatorEntered System Message 16-characters max Write Only
$PasswordEntered System Message 16-characters max Write Only
$VerifiedUserName System Message 16-characters max Read Only

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

Creating Authority Check Functionality with OS or ArchestrA Security


In regulated industries, there are instances where a change in a value must be authorized by a
person other than the operator that is logged in. This function allows you to implement a Done by/
Checked by logic in the application. The InvisibleVerifyCredentials() function combined with the
$VerifiedUserName can be used to verify the credentials of a user other than the currently logged
in user. $VerifiedUserName contains the verified user's full name if the call to
InvisibleVerifyCredentials() is successful; the return of InvisibleVerifyCredentials() is the
access level set for the user that was verified. If the call fails, then $VerifiedUserName tag will be
set to null and the return value is -1.

Logging in Using the Current User


In some designs, company policy may require each user to log in to the operating system and log
out of the operating system when switching users. In such cases, the InTouch designer may use
the LogonCurrentUser(); script function instead. This would not require displaying a separate log
in dialog box for InTouch. However, this design, depending on environment and configuration, may
require waiting for WindowViewer to start when operators are switched.

Script Functions in InTouch Related to All Security Models


InvisibleVerifyCredentials()
Checks to verify the credentials of the given user without logging the user in to InTouch.
Syntax
AnalogTag=InvisibleVerifyCredentials
( "UserId","Password", "Domain" );
Remarks
If the supplied combination of user, password, and domain are valid, the corresponding
access level associated with the user is returned as an integer; in all other cases, -1 is
returned. This call does not change the currently logged in user.
Set the Domain argument to blank (“”) or InTouch if the Authentication Mode is InTouch and
to Galaxy if the Authentication Mode is ArchestrA.
PostLogonDialog()
Brings up the InTouch Logon Dialog and returns TRUE.
Syntax
DiscreteTag=PostLogonDialog();
Remarks
This brings up the InTouch Logon Dialog and returns TRUE.

InTouch HMI 2017 Update 3


9-10 Module 9 – Security

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.

Script Functions Specific to Operating System Security


AddPermission()
Sets the Access Level to a particular group or user in the specified domain.
Syntax
DiscreteTag=AddPermission
( "Domain", "Group", AccessLevel);
Remarks
This is valid for OS security mode only. An attempt is made to reach the account Account on
domain Domain. If successful, a TRUE is returned and the access level AccessLevel is
assigned to the account in the internal records in InTouch for use during authorization when a
user logs in. In all other cases, a FALSE is returned.
The Group parameter can be any valid group or user defined in the specified Domain
parameter. It is also important to note that the access level set for each group does not have
anything to do with the rights for each group. For example, nothing prevents you from giving
the Guests group an access level of 9999 or the Administrators group an access level of 100.

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.

Script Functions Specific to ArchestrA Security


IsAssignedRole()
Used to find out if current logged in user has the indicated role.
Syntax
DiscreteTag=IsAssignedRole( "RoleName" );
Remarks
This is valid for ArchestrA security mode only and applies to the currently logged in user. If a
user is currently logged in and has the role RoleName assigned in the ArchestrA IDE, a TRUE
is returned; in all other cases, a FALSE is returned.

InTouch HMI 2017 Update 3


9-12 Module 9 – Security

Wonderware Training
Lab 23 – Setting Up and Using OS Security 9-13

Lab 23 – Setting Up and Using OS Security

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

InTouch HMI 2017 Update 3


9-14 Module 9 – Security

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.

OS Security has been enabled.


3. On the Scripts pane, double-click Application.

Wonderware Training
Lab 23 – Setting Up and Using OS Security 9-15

The Application Scripts dialog box appears.

4. On the Condition Type drop-down list, select On Startup.

InTouch HMI 2017 Update 3


9-16 Module 9 – Security

5. In the script body, enter the following:

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.

DIM Success AS DISCRETE;


Success = AddPermission("CLOUD","Application Administrators", 9000);
Success = AddPermission("CLOUD","Plant Supervisors 1", 8000);
Success = AddPermission("CLOUD","Plant Operators 1", 5000);

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.

10. Click Close.

Wonderware Training
Lab 23 – Setting Up and Using OS Security 9-17

Monitor New User Logins


11. In the Scripts pane, double-click Data Change.

12. In Tagname[.field], enter $Operator.

InTouch HMI 2017 Update 3


9-18 Module 9 – Security

13. In the script body, enter the following:

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;

14. Click OK.

Wonderware Training
Lab 23 – Setting Up and Using OS Security 9-19

Create Security Logon Symbol


Next, you will create a symbol that will be used to call up the log on prompt, log off the current user,
and display security tags.
15. In the WindowMaker Training toolset, create a new symbol named SecurityLogon and open
it for editing.
16. Embed the Situation Awareness Library\Input\SA_NumericalEntry symbol.
17. Configure the Properties pane as follows:

Name: DisplayAccessLevel
Type: Output
EngUnits: False
QualityStatusIndicator: False
Outline: False

18. Substitute strings as follows:

Old New
##.## #
Label Access Level

19. Right-click DisplayAccessLevel and configure the custom properties as follows:

Name Default Value Visibility


LabelVisible True Public
PV InTouch:$AccessLevel Public

InTouch HMI 2017 Update 3


9-20 Module 9 – Security

20. Embed the Situation Awareness Library\Input\SA_TextEntry symbol below


DisplayAccessLevel.

21. Configure the Properties pane as follows:

Name: DisplayOperator
Type: Output
QualityStatusIndicator: False
Outline: False

22. Substitute strings as follows:

Old New
##.## #
Label Operator

23. Right-click DisplayOperator and configure the custom properties as follows:

Name Default Value Visibility


LabelVisible True Public
PV InTouch:$Operator Public

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.

30. On the Alignment toolbar, click Make Vertical Spacing Equal.

The canvas will look similar to the following image.

31. Reposition the elements to make room on the left for buttons that will be added in the following
steps.

Next, you will create buttons to log on and log off.


32. On the left of the elements, draw a button labeled Log On, and configure it as follows:

Name: ButtonLogOn
Element Style: Intensity1

InTouch HMI 2017 Update 3


9-22 Module 9 – Security

33. Double-click ButtonLogOn.


34. In the Edit Animations dialog box, add an Action Scripts animation with the Trigger type
configured as OnLeftClick/Key/TouchDown:

35. Click Script Function Browser .


36. In the Script Function Browser, expand InTouch.
37. Scroll down, and select PostLogonDialog.

38. Click OK.


The PostLogonDialog(); script function is entered into the script.

39. Click OK.


40. Duplicate the button, and place it below ButtonLogOn.
41. Name the duplicate ButtonLogOff.
42. Substitute strings, and replace Log On with Log Off.
43. Double-click ButtonLogOff.
44. In the Action Scripts animation, clear the script.

Wonderware Training
Lab 23 – Setting Up and Using OS Security 9-23

45. Click Script Function Browser button.


46. In the Script Function Browser, expand Graphic Client.
47. Select Logoff.

48. Click OK.


The Logoff(); script function is entered into the script.

49. Click OK.


50. Save and close SecurityLogon.

InTouch HMI 2017 Update 3


9-24 Module 9 – Security

51. In WindowMaker, ensure only the Menu window is opened.


52. Embed the SecurityLogon symbol on the right side of the Menu window.

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.

54. Click the Log On button.


The Log On dialog box opens.

Wonderware Training
Lab 23 – Setting Up and Using OS Security 9-25

55. In the Log On dialog box, enter the following:

User name: maryl


Password: ww
Domain: CLOUD

Note: Your instructor will provide the authentication information.

56. Click OK.


The SecurityLogon symbol will look similar to the following image.

57. Click Log Off.


The SecurityLogon symbol will look similar to the following image.

58. Click Development!.

InTouch HMI 2017 Update 3


9-26 Module 9 – Security

Create Local Users and Groups


(Non-domain Classroom Setting Only)
These additional steps are for classrooms without a domain set up. You must create local users
and groups before starting this lab. Your instructor will inform you if you need to do this setup.
In the following steps, you will start Computer Management and create users.
1. Open Computer Management.
2. Expand Local Users and Groups.
3. Right-click Users, and select New User.

4. Configure each of the users as follows:

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:

Group name Members


Application Administrators maryl
Plant Supervisors 1 karent
Plant Operators 1 johnj

8. Click Close.
9. Close Computer Management.
10. Return to “Set Up OS Security” on page 9-14 and continue this lab.

InTouch HMI 2017 Update 3


9-28 Module 9 – Security

Wonderware Training
Section 2 – Lock Down Your Application 9-29

Section 2 – Lock 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.

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.

Configuring Inactivity to Automatically Log off


You can configure your application to automatically log off the operator when there has been no
activity for a specified period of time by using the warning and timeout settings.
On the Special menu, click Configure, and then click WindowViewer, or in the Application
Explorer under Configure, double-click WindowViewer. The WindowViewer Properties dialog
box appears with the General tab active. In the Application Explorer, you can also right-click
WindowViewer, and then click Open.
In the Warning field, enter the number of seconds that can elapse with no operator activity (mouse
clicks or keystrokes) before the system discrete tagname $InactivityWarning is set to 1 (True).
When the Inactivity Warning is set to 0, there will not be an inactivity warning.

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

InTouch HMI 2017 Update 3


9-30 Module 9 – Security

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.

Securing the Application


The following section explores securing the application in greater detail. As discussed in the
previous module, the three major aspects of security are as follows:
 Securing the Operating System
 Auditing
 Securing the Application

Customizing the Runtime Environment


Like WindowMaker, WindowViewer includes many options to customize your runtime
environment. For example, you can set the blinking speed for blinking objects, the system
inactivity timeout and warning values, and the windows that are automatically opened when
WindowViewer is started from its icon or its menu command.
Securing any InTouch application involves identifying ways the application can be accessed by
users in the Windows environment, but also includes remote clients attempting to retrieve data
from WindowViewer. InTouch allows you to define various options to increase the robustness and
to secure your application by turning off undesired menu bar entries, certain Alt, Esc, and Win key
keystrokes and key combinations, as well as operating system lockdown. You can use these
options to prevent users from performing potentially dangerous actions. In combination, these
features ensure that users do not have access to change the application environment, close the
application, or escape from the application to start unauthorized programs.
Secure the operating system by limiting user access to applications outside of InTouch.
Operating system security is configured from the WindowViewer Properties dialog box,
Windows Configuration tab. This is accessed on the Special menu by selecting
Configure | WindowViewer.
Here you can turn off undesired menu bar entries, certain keystrokes, and other settings to ensure
that users do not change the application’s environment, close the application, or escape from the
application to other programs.
Use Menus settings to show or hide different menu options within WindowViewer, hide the menu
bar, prevent the operator from switching to WindowMaker, and prevent the operator from starting
and stopping QuickScripts during runtime.

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.

Restricting User Input


InTouch includes the script function EnableDisableKeys() that enables/disables the Alt, Tab, or
Win keys in runtime. Disabling these keys prohibits users from switching between windows
applications or accessing the task bar. This function, combined with WindowViewer settings to
Always Maximize and hide menu bar and Windows control options, will effectively secure the
operating system.
Another common practice to hide/show the menu bar in View is to create a popup window with its
X,Y coordinates set to 0,-38 with a height of 38 pixels and a width equal to the display resolution
(e.g. 1280). This example uses the Microsoft Windows Server 2003 Operating System, with a
screen resolution of 1280 x 1024. Values will differ depending on the Operating System and
resolution used. Values will be -48 and +48 if XP look and feel is applied.

Auditing the Application


When a security model is applied to an InTouch application, the Alarm and Event sub-system
provides an audit trail associating users to all alarms/events that occur during the time that they
are logged onto the system.
Both the Distributed Alarm Object and the Alarm Display ActiveX control provide for displaying the
logged on Operator name.

Scripting and System Tags


InTouch provides a number of System tags and script functions that allow you to configure security
for the individual application. By applying security to your application, you can control specific
functions a user is allowed to perform by linking those functions to internal tagnames. Once a user
is validated and logged on to the InTouch application, the $Operator and $AccessLevel system
tags contain information about the user and their access level.
To log on to an InTouch application, users can select on the Special menu, Security | Logon, call
a script function to display a logon dialog box, or log on via a custom logon window.
$Operator and $AccessLevel are tags used to secure InTouch applications. These are system
tags used to control what a user has access to during runtime. For example, to disable a
pushbutton, assign a Disable or Visibility animation link to it with an expression, such as
$AccessLevel < 9000 or $Operator == xxx.

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.

InTouch HMI 2017 Update 3


9-32 Module 9 – Security

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.

Configuring Log In and Log Off


Logging on to and logging off from an InTouch application varies by the type of security used to
protect an application. You can configure the application to automatically log off the user after
specified inactivity duration.

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

InTouch HMI 2017 Update 3


9-34 Module 9 – Security

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

Lab 24 – Locking Down Your Application

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

InTouch HMI 2017 Update 3


9-36 Module 9 – Security

Configure Automatic Log Off


In the following steps, you will open WindowViewer Properties and configure the Automatic Log
Off settings.
1. Close WindowViewer.
2. On the WindowMaker Special menu, select Configure | WindowViewer.
3. On the General tab, Inactivity area, Timeout field, enter 20 seconds.

4. Click OK.
5. Ensure only the Menu window is open.

Wonderware Training
Lab 24 – Locking Down Your Application 9-37

Test Automatic Logoff in Runtime


Next, you will test what you have just configured in runtime.
6. Click Runtime.
7. Logon as maryl.

Note: Your instructor provided the domain name and password.

8. Wait 20 seconds until automatic logoff occurs.


maryl is logged off after 20 seconds.

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.

InTouch HMI 2017 Update 3


9-38 Module 9 – Security

Create the Home Window


Next, you will create a Home window to replace other windows in the application.
12. On the WindowMaker File menu, select New Window.
13. Configure the Window Properties dialog box as follows:

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.

14. Click OK.


15. In the ArchestrA Graphics Toolbox, expand ArchestrA Symbol Library and Clocks.

Wonderware Training
Lab 24 – Locking Down Your Application 9-39

16. Drag ClockAnalogWall to the Home window.

InTouch HMI 2017 Update 3


9-40 Module 9 – Security

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.

19. Click OK.

Wonderware Training
Lab 24 – Locking Down Your Application 9-41

Set the Home Windows


Next, you will set the Home Windows for your application.
20. In WindowMaker, open WindowViewer Properties.
21. Click the Home Windows tab, and check the Home and Menu window check boxes.

22. Click OK.

Note: The WindowViewer Home Windows feature will be tested in a future lab.

InTouch HMI 2017 Update 3


9-42 Module 9 – Security

Test What You Have Built


Next, you will test the Home window functionality in runtime.
23. Click Runtime.
The Menu and Home windows display.

24. Log on as maryl.


The KPI, Mixer, and Current Alarms windows appear.

Wonderware Training
Lab 24 – Locking Down Your Application 9-43

25. In the Menu window, click Log Off.


The Home window appears.

26. In the Menu window, Nav combo box, select Mixer.


With no one logged in, notice the Mixer window opens. An unauthorized user can observe all
the plant processes and start and stop pumps. The ability to navigate when no one is logged in
is unwanted behavior. Now you will apply additional security to lock down the application.

27. Click Development!.

InTouch HMI 2017 Update 3


9-44 Module 9 – Security

Add Security to the Nav Combo Box


Next, you will add an animation to the Nav combo box so that it is disabled, unless the logged on
user has the appropriate access level.
28. In the Menu window, right-click the Nav combo box, and select Animation Links.
29. Click Disable.

30. In the Expression field, enter $AccessLevel < 5000.


31. In the Disabled State area, select On.

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

Test What You Have Built


Next, you will test the Nav combo box functionality in runtime.
34. Click Runtime.
35. Try to click the Nav combo box, and notice it is disabled.
36. Log on as johnj.
37. In the Menu window, click the Nav combo box, and select Mixer.
The Mixer window opens.
38. Click Log Off.
39. On the WindowViewer File menu, select Open Window, select Mixer, and then click OK.
The Mixer window opens even though no one is currently logged on. An unauthorized user
can open windows by clicking the File menu. You will apply additional security to prevent this.
40. Click Development!.

Hide the Menu Bar


Next, you will edit the Menu window to hide the WindowViewer menu bar to prevent users from
clicking on it.
41. In the Windows & Scripts pane, right-click Menu, and select Properties.
42. Configure the dimensions of the Menu window as follows:

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.

InTouch HMI 2017 Update 3


9-46 Module 9 – Security

44. In the Menu window, right-click, and select Select All.


45. Press and hold the Ctrl key, and then press the Down Arrow key once to reposition all of the
graphics on the Menu window.

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.

Test What You Have Built


Next, you will test the changes in runtime.
46. Click Runtime.
The WindowViewer menu bar is now hidden by the Menu window, and the mouse cannot be
used to access the File menu.
Next, you will test keyboard access.

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.

47. Press and hold the Alt key, and press F.


The WindowViewer File menu appears on top of the Menu window, so the application is not
secure from keyboard actions.

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!.

InTouch HMI 2017 Update 3


9-48 Module 9 – Security

Enable or Disable Keys


Next, you will use a script function to control access to certain key stroke combinations.
51. Close WindowViewer.
52. In the WindowMaker Scripts pane, double-click Application.
53. On the Condition Type drop-down list, confirm On Startup is selected
54. In the script body, add a line to the end of the current script.
55. In the Functions area, click the All button.

56. In the Choose function list, select EnableDisableKeys.

EnableDisableKeys(AltKey,EscKey,WinKey); is inserted in the script field.

Wonderware Training
Lab 24 – Locking Down Your Application 9-49

57. Modify the line of script as follows:

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.

58. Click OK.

InTouch HMI 2017 Update 3


9-50 Module 9 – Security

Next, you will create a Data Change script.


59. In the Scripts pane, right-click Data Change, and select New.
60. In Tagname[.field], replace <Tagname> with $AccessLevel.
61. In the script area, replace the script with the following:

Note: You may copy and paste the script from the C:\Training\Lab 24 - Locking Down
Your Application.txt file.

IF $AccessLevel >= 8000 THEN


EnableDisableKeys(0,0,0); {Administrator}
ELSE
IF $AccessLevel >= 5000 THEN
EnableDisableKeys(1,0,0); {Supervisor and Operator}
ELSE
EnableDisableKeys(1,0,1); {None}
ENDIF;
ENDIF;

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

Test What You Have Built


Finally, you will test the keyboard functionality in runtime.
63. In WindowMaker, ensure only the Menu and Home windows are open.
64. Click Runtime.
65. Press Alt + F.
Notice that you cannot make the File menu appear over the Menu window.
66. Press Ctrl + Shift + Esc.
Notice that Task Manager does not start.
67. Press Win.
Notice that you cannot use the keyboard to open the Start menu.
68. Log on as one or more of the users johnj, karent, or maryl and repeat the Alt + F,
Ctrl + Shift + Esc, and Win tests.

Note: Each user has access to different features. For example, karent and maryl have
different access than johnj.

69. Click Development!.

InTouch HMI 2017 Update 3


9-52 Module 9 – Security

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

Section 1 – Manage ArchestrA Symbols


This section will explain how to manage ArchestrA symbols including exporting, importing, and
restoring library symbols if accidentally deleted.

Export and Import ArchestrA Symbols


In a Modern InTouch Application, WindowMaker provides support for exporting and importing your
ArchestrA symbols. Using export and import allows graphics from one application to be reused in
another Modern or Managed application. Additionally, a mature starting point containing a library
of all custom graphics can be imported into a new application to save time. Or export and import
can be used to manage revisions of change in file form, to permit for example restoring an older
working version of a graphic design or it may be used to upgrade an older library symbol with the
latest.
If an original symbol is accidentally deleted from the ArchestrA Graphic Toolbox, a file for each of
the main graphic libraries called ArchestraSymbolLibrary.aaPKG and Situational Awareness
Symbol Libarary.aaPKG are located in the path - C:\Program Files
(x86)\ArchestrA\Framework\Bin. These may be sued to restore a missing symbol. To import these
files use the WindowMaker File | Import | ArchestrA Graphics menu. These imports however will
replace all of the original symbols found in these libraries which includes overwriting any changes
which may have been made after installation to the base symbols. It is for this reason it is never
recommended to modify any of the original library symbols in an InTouch Application. Each
symbol must have a unique name within the entire Modern InTouch Application. If another symbol
exists in the application with the same name as an imported symbol the existing symbol will be
wiped out without a warning of any kind and replaced by the imported symbol of the same name.
To export an individual symbol or a specific toolset containing symbols, in WindowMaker from the
ArchestrA Graphic Toolbox simply right-click the toolset or symbol you wish to export and select
Export | Symbols. To import an individual symbol, in WindowMaker from the File | Import menu
select ArchestrA Graphics. Importing symbols resolves name resolution conflict by always
replacing the graphic with the same name in the ArchestrA Graphic Toolbox with the one being
imported from the file. There is no prompt to indicate you are replacing an existing graphic, so be
cautious. By exporting individual graphics directly from the ArchestrA Graphics Toolbox it is
possible to import one of these files in order to replace a graphic of the same name in the library.
This technique could be used to upgrade or revert the revision of a symbol.
Toolsets are preserved in export and import operations, but these will not protect you from a
naming conflict as the global namespace for symbols ignores toolset names. While toolset names
are preserved aesthetically and for symbol organizational purposes during in the export and import
operations, these however do not play any role in the naming of symbols.

Export or Import Windows Containing ArchestrA Graphics


When a window containing ArchestrA symbols is imported into another InTouch application the
ArchestrA graphics are not imported along with the window. When this window is opened,
placeholders on the window will be shown indicating no graphic exists. Separately, the ArchestrA
symbols must be exported from the original application and imported into the new application for
the graphics to appear on the imported window.

InTouch HMI 2017 Update 3


10-4 Module 10 – Application Maintenance

Modify or Reuse Original Library Content


If you need to make changes to original library content there are several approaches. First is to
duplicate the original symbol and provide a unique name for the duplication. This avoids a naming
conflict if you should ever reimport the original installation library, because it will not overwrite any
symbol which is not part of the original manifest of symbol names from the library. The second
method is to open your custom symbol and the original symbol in two instances of the symbol
editor, and copy all or part of the original and paste into your custom symbol. This method will get
you an graphics and animation as part of the paste operation, but will not include predefined and
named scripts, or custom properties. The third method is to embed the original symbol, right click
and select Embedded Symbol | Convert to Group. This will convert the linked instance into an
actual editable group element and will also attempt to add the custom properties from the original
symbol to your custom symbol.

A Common Misunderstanding of Cursor Focus


After embedding a graphic on a window in WindowMaker using the drag and drop method, though
the embedded instance has resize handles around the graphic, the actual focus in WindowMaker
is on the symbol in the ArchestrA Graphic Toolbox. If you press the Delete key to delete the
selected graphic, instead of deleting the graphic on the window, the original graphic from the
toolbox will prompt for deletion. The indicator you are deleting the wrong graphic only appears
when removing a graphic from the library. Therefore, if the focus is actually on the embedded
instance on the window, no prompt will appear to delete the graphic. If you accept the prompt and
delete an original symbol from the library that was installed with the product installer it will be
removed only from the copy of the library associated with this single InTouch application.
To restore the missing graphic use the import method described above. To avoid this problem in
the first place, click on the embedded instance on the window to ensure focus is on the graphic on
the window, not on the graphic in the library, before pressing the Delete key or use the right-click
context menu and select Erase which automatically places focus on the embedded instance
instead of the symbol in the ArchestrA Graphic Toolbox. It should be noted that the orange lock
symbol found on symbols from the Situational Awareness Library does not prevent these symbols
from being deleted, it only prevents symbols from being edited (the orange lock icon indicates
read-only status of the symbol).

Wonderware Training
Section 2 – Application Backup and Restore 10-5

Section 2 – Application Backup and Restore


This section will explain how to export a Modern application to an .aaPKG file. This section will go
on to explain how to import a Modern application from an .aaPKG file.

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.

Applications can be reused anywhere InTouch Application Manager is installed. It is considered a


good practice to restore your application as a separate application and not to overwrite the existing
application. Once you have verified that the restored application functions properly, you can then
delete the original application, if desired.

InTouch HMI 2017 Update 3


10-6 Module 10 – Application Maintenance

Wonderware Training
Lab 25 – Backing Up and Restoring a Modern InTouch Application 10-7

Lab 25 – Backing Up and Restoring a Modern


InTouch Application

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

InTouch HMI 2017 Update 3


10-8 Module 10 – Application Maintenance

Back Up the Application


In the following steps, you will use the InTouch Application Manager to create a backup of your
application.
1. Close WindowViewer and WindowMaker.
2. Open InTouch Application Manager.
3. Ensure InTouch Training Application is selected.

4. On the toolbar, click the Export button.

5. In the Export InTouch Application dialog box, navigate to C:\Training, and click Save.
The Export InTouch Application progress is displayed.

The export will take a few moments to finish.


The InTouch Training Application.aaPKG file appears in the Training folder.
6. Close Windows Explorer.

Wonderware Training
Lab 25 – Backing Up and Restoring a Modern InTouch Application 10-9

Restore the Application


Next, you will use the InTouch Application Manager to restore your application from the backup.

7. On the toolbar, click the Import button.

8. In the Import InTouch Application dialog box, click File.

InTouch HMI 2017 Update 3


10-10 Module 10 – Application Maintenance

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.

10. Click Next.


The Create New Application dialog box appears.
11. Retain the default storage location, and click Next.
12. In the directory location field, enter RestoredTrainingApp.

Wonderware Training
Lab 25 – Backing Up and Restoring a Modern InTouch Application 10-11

13. Click Next.


14. In the Name and Description fields, enter Restored Training Application.

15. Click Finish.


The Create New Application progress is displayed.

This will take a few moments to finish.


In the InTouch Application Manager, Restored Training Application appears, and the Import
InTouch Application progress is displayed.

This will take a moment to finish.

InTouch HMI 2017 Update 3


10-12 Module 10 – Application Maintenance

Test the Restored Application


Finally, you will open the restored application in WindowViewer, and verify the Home Windows
setting.

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.

18. Close WindowViewer.


19. Open InTouch Application Manager.
20. Double-click InTouch Training Application to open the original training application in
WindowMaker.
21. In the Windows to Open dialog box, ensure only the Menu window is checked, and click OK.

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

Section 1 – Application Publishing


This section will explain how to publish your InTouch application for your production environment.

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.

Published vs. Modern InTouch Application


A published application does not serve as a backup copy of your application. A published
application does not allow InTouch application edits, or edits to ArchestrA symbols. Publishing can
be used as a tool to conceal intellectual property and prevent the theft of your application, but only
if you build with ArchestrA graphic symbols.
Also, a published InTouch application cannot be restored back into the InTouch Application
Manager. Only a properly exported.aaPKG backup file may be restored in this way.

InTouch HMI 2017 Update 3


11-4 Module 11 – Application Publishing and Distribution

Wonderware Training
Section 2 – Network Application Distribution 11-5

Section 2 – Network Application Distribution


This section will explain how to configure Network Application Development (NAD) and how NAD
delivers changes to the production machine.

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.

In the NAD architecture, a master copy of an application is maintained on a central network


location. Each View node loads that network application as they would in a server-based
architecture, but instead of running the application from the server, the application is copied to and
run from a user-defined location. This provides the client-based advantage of redundancy. In the
example below, the two View nodes both have the master application registered from the
development node, but actually run it from their own hard drives.
When a View node copies and runs a master application, it automatically monitors for changes in
the master copy. These changes are indicated by a flag in the master application directory. This
flag is set manually when the application developer uses the WindowMaker Special | Notify
Clients command while editing that application. When this flag changes, each View node has a
user-definable action that specifies the response of that node. This can range from ignoring the
flag to automatically shutting down and restarting the View node, which reloads the master
application.

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

InTouch HMI 2017 Update 3


11-6 Module 11 – Application Publishing and Distribution

 View is suspended while application is transferred and compiled

Configuring an InTouch Application for NAD


The Production node can be configured to handle pulling changes to the application in the
following ways:

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.

Manual NAD Operations

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

ReloadWindowViewer() This function will automatically update 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 without interrupting the
operation of that node.
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 a dynamic update of WindowViewer when it is convenient. This function
effectively replaces the RestartWindowViewer() function.

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.

Application Editing Locks


InTouch applications can only be edited by one developer at a time. To prevent multiple
developers from trying to edit an application, WindowMaker locks an application during the edit
session. If you try to load an application into WindowMaker that has a lock created, you will receive
a message telling you that the application cannot be edited because it is being edited by another
computer. The name of the node editing the application will also be stated in the message.

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.

Dynamic Resolution Conversion (DRC)


Dynamic Resolution Conversion (DRC) works with other distributed features to provide
independence from screen resolution restrictions. In a NAD architecture, an InTouch application is
created and maintained on a development node and then copied to several View nodes. DRC
allows all of these nodes to view the application even if they are running at different screen
resolutions.
DRC enables each View node to scale the application to a number of user-defined options,
including a custom resolution. This scaling takes place while WindowViewer compiles the
application and does not require WindowMaker.

Environmental Setup Required for Production Nodes


Environmental dependencies such as data sources, file paths, network connections, and other
resources must be properly configured in the master application so that when the application is
distributed to the individual Production nodes, each will have access to the same resources that
the master application uses.

InTouch HMI 2017 Update 3


11-8 Module 11 – Application Publishing and Distribution

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

Lab 26 – Distributing an InTouch Application

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

InTouch HMI 2017 Update 3


11-10 Module 11 – Application Publishing and Distribution

Share the Application Folder


In the following steps, you will share the Training folder on the Engineering node, so that it can be
accessed by the Production node.
1. Open Windows Explorer, and navigate to the C: drive.
2. Right-click the Training folder, and select Share with | Specific people.
The File Sharing dialog box appears.

3. Click Share.

Wonderware Training
Lab 26 – Distributing an InTouch Application 11-11

A confirmation message appears.

4. Click Done.
5. Close Windows Explorer.

InTouch HMI 2017 Update 3


11-12 Module 11 – Application Publishing and Distribution

Configure the Visualization Station


Next, you will notify clients from WindowMaker to prepare the application for distribution to the
Production node which represents a workstation used by HMI runtime users. Then, you will switch
to the Production node and configure NAD to download a copy of the application and run it.
6. On the WindowMaker Special menu, select Notify Clients | Notify Clients Now.

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.

8. On the Production node, start InTouch Application Manager.


The Welcome to InTouch Application Manager dialog box appears.
9. Click Next.
10. In the Starting directory field, enter C:\Training, and click Finish.
The InTouch Application Manager opens.

Wonderware Training
Lab 26 – Distributing an InTouch Application 11-13

11. On the toolbar, click the Node Properties button.

The Node Properties dialog box appears.


12. Check the Enable Network Application Development check box.
13. In the Network Application Development area, Local working directory field, enter
C:\Training\NAD.
14. In the Change Mode area, select Prompt user to restart WindowViewer.

15. Click OK.

16. On the toolbar, click the Find button.

InTouch HMI 2017 Update 3


11-14 Module 11 – Application Publishing and Distribution

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.

18. Click OK.


The InTouch Training Application appears in the InTouch Application Manager.
19. Ensure the InTouch Training Application is selected.

Wonderware Training
Lab 26 – Distributing an InTouch Application 11-15

20. On the toolbar, click the WindowViewer button.


The application starts with Home Windows displayed.

InTouch HMI 2017 Update 3


11-16 Module 11 – Application Publishing and Distribution

Make a Change to the Application


Finally, you will change to the application on the Engineering node and notify the Production node
that there are changes. Then, you will observe the changes on the Production node.
21. Switch to the Engineering node.
22. In WindowMaker, change the background color of the Menu window to light blue.
23. Click Save All Windows.
24. On the Special menu, select Notify Clients | Notify Clients Now.
25. Switch to the Production node.
A message appears asking if you want to restart WindowViewer.

26. Click Yes.


27. When WindowViewer reopens, verify the Menu window has a light blue background.

28. Switch to the Engineering node.


29. In WindowMaker, change the color of the Menu window to any color of your choice.
30. Click Save All Windows.
31. Close WindowMaker.
A message appears asking if you want to notify all NAD clients.

32. Click Yes.


After publishing symbols is complete, WindowMaker closes.
33. Switch to the Production node.

Wonderware Training
Lab 26 – Distributing an InTouch Application 11-17

34. On the WindowViewer popup message, click Yes.


WindowViewer restarts and shows the Menu window changes.

35. Switch to the Engineering node.

InTouch HMI 2017 Update 3


11-18 Module 11 – Application Publishing and Distribution

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

Section 1 – Web Client

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.

Enable Web Client


By default, the Web Client will be disabled to secure systems where no decision has been made to
enable a web server on the installation machine. You must have administrative privileges to
enable or disable the Web Client. The Web Client is enabled from the InTouch Application
Manager toolbar using the Click to start Web Server for InTouch Web Client button. If Web Client
was not enabled from the InTouch Application Manager, by clicking the Web Client fast switch in
WindowMaker will prompt to start the web server.
This tool in the InTouch Application Manager represents the Web Client disabled:

InTouch HMI 2017 Update 3


12-4 Module 12 – Web Client

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:

Configure InTouch Application Graphics for Viewing in a Web Browser


Using the ArchestrA Graphic Toolbox you can configure the Graphic Toolset folder, containing the
application graphics that will be displayed on the web browser. Only graphics stored within the
folder, enabled with Set Web Client Root, are displayed on the Web Client menu. By default, all
graphics in the WindowMaker ArchestrA Graphics Toolbox are converted, because the Web Client
Root folder is configured for the top node in the toolbox. The Root folder is marked in the
ArchestrA Graphic Toolbox with a Home icon.

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.

Web Client Fast Switch


When using the Web Client with InTouch HMI, WindowViewer must be running to provide data for
the Web Client. Initially, the Web Client fast switch in WindowMaker may be disabled if the
InTouch application path is not set to the current application path. This can occur after importing
and starting a restored InTouch application or after switching InTouch applications. For InTouch
HMI, start WindowViewer with the Runtime fast switch will do the following:
 Set the application path to the current application and build the application's web folder
 Enables the Web Client fast switch in WindowMaker (if disabled)
 Starts WindowViewer, which provides data for Web Client animations

InTouch HMI 2017 Update 3


12-6 Module 12 – Web Client

Web Client Page


The InTouch Web Client page provides various options to inform and organize the user
experience using icons on the page. The following table describes these options.

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

Pan and Zoom Support


InTouch Web Client supports the pan and zoom gestures for all supported browsers and devices.
The pan and zoom capabilities are similar to Frame window support on WindowViewer. When a
graphic in the web browser is zoomed in from a non-mobile device, the zoom percentage is
displayed in the lower left corner of the horizontal scrollbar. The zoom percentage is limited to a
maximum of 500%.

InTouch HMI 2017 Update 3


12-8 Module 12 – Web Client

Symbol Changes Reflected Automatically


Graphic-related changes are made using the Symbol Editor, and those changes are automatically
refreshed in the browser. However, changes in Quality and Status Style, Element Style, and
Formatting Styles (for InTouch HMI) are propagated only after making the following graphic
changes or re-launching WindowViewer.
 Content of symbol is updated and saved
 Symbol is created, imported, or deleted
 Symbol is moved to a different toolset folder
 Root folder or Home symbol assignment is updated

Displaying Individual Symbols Via URL


To display an individual symbol in a browser you may use the following syntax:
http://<hostname>/InTouchWeb/api/symbol/<graphicname> or
http://<IPAddress>/InTouchWeb/api/symbol/<graphicname>
For example, http://production/InTouchWeb/api/symbol/tankfarm, might be used to display a mixer
symbol that represents a production vessel in a tank farm.

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

Lab 27 – Using the Web Client

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

InTouch HMI 2017 Update 3


12-10 Module 12 – Web Client

Enable and Start the Web Client


In the following steps, you will enable the Web Client to start a web site hosting service, then you
will use the Web Client fast switch in WindowMaker to start the Web Client.
1. Start the InTouch Application Manager.

2. Click the Enable Web Client button.

The Enable Web Client button turns blue to indicate that it has been enabled.

3. Ensure the InTouch Training Application is selected and click WindowMaker.


The Windows to Open dialog box appears.
4. In the Windows to Open dialog box, click OK.
5. Click Runtime to open WindowViewer.

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.

8. Click in the Search Symbol field.

InTouch HMI 2017 Update 3


12-12 Module 12 – Web Client

9. In the Search Symbol field, enter Clock.

10. In the search results, click ClockDigital12.

Wonderware Training
Lab 27 – Using the Web Client 12-13

The symbol is displayed.

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.

Set the Web Client Root Folder and Home Symbol


Next, you will use Web Client Root Folder and Web Client Home Symbol to limit the Web Client
so it only shows symbols you have configured in this course.
11. Close the web browser.
12. In WindowMaker, ArchestrA Graphic Toolbox, right-click the intouch training application
toolset, and select Set Web Client Root Folder.

InTouch HMI 2017 Update 3


12-14 Module 12 – Web Client

13. Expand the intouch training application toolset, right-click KPI, and select Set Web Client
Home Symbol.

14. Click the Web Client fast switch.

After a few moments, the default web browser opens, and the Home symbol appears.

Wonderware Training
Lab 27 – Using the Web Client 12-15

15. Click the Web Client menu.

The Web Client displays the symbols in the Web Client root folder. In this example, the Root
folder contains only the KPI symbol.

16. Close the web browser.

InTouch HMI 2017 Update 3


12-16 Module 12 – Web Client

Add Symbols to the Root Folder


Next, you will drag symbols to the Root folder to make them available in Web Client.
17. In the WindowMaker, ArchestrA Graphic Toolbox, expand the Training toolset.
18. Drag the Mixer and Current Alarms symbols into the intouch training application toolset.

19. Click Web Client.


After a few moments, the default web browser opens, and the Home symbol appears.
20. In the Web Client menu, click Mixer.

Wonderware Training
Lab 27 – Using the Web Client 12-17

The Mixer symbol appears.

InTouch HMI 2017 Update 3


12-18 Module 12 – Web Client

Use the Zoom and Pan Features of Web Client


Next, you will use your mouse to zoom and pan a symbol in the browser.
21. With the Ctrl button held down on the keyboard, and the cursor hovering over the middle of
the Mixer symbol, scroll the mouse wheel up to zoom in.

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.

The KPI symbol is displayed.

Wonderware Training
Lab 27 – Using the Web Client 12-19

25. In the Web Client menu, click Current Alarms.


The Current Alarms symbol is displayed.

The buttons at the bottom of the symbol are non-functional because the Web Client does not
support write functionality.

InTouch HMI 2017 Update 3


12-20 Module 12 – Web Client

Show Unsupported Features in Web Client


Next, you will use a troubleshooting feature of Web Client to view a list of unsupported features for
the current symbol.
26. Click the Unsupported Features icon.

A list of features not year supported appears.

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.

28. Close the list.

29. In the Current Alarms symbol, click the Tag column header.

The alarms list is sorted by Tag.

InTouch HMI 2017 Update 3


12-22 Module 12 – Web Client

Build Custom Navigation


Next, you will use Hyperlink animation to call the URL of a specific symbol. Without the Hyperlink
animation, the URL can also be used in the address bar of the web browser to call a specific
symbol.
30. In the Web Client menu, select Mixer.
31. Leave the browser open, and return to WindowMaker.
32. Resize WindowMaker so you can see the web browser with the Mixer symbol behind it.

Wonderware Training
Lab 27 – Using the Web Client 12-23

33. In WindowMaker, ArchestrA Graphic Toolbox, intouch training application toolset,


double-click the Mixer symbol to open it for editing.
34. Duplicate the Alarms button and place the duplicate to the right of the original.
35. With the duplicate selected, in the Properties pane, name the button KPIButton and change
the Text to KPI.

36. In the Properties pane, Animations area, select Action Scripts and click Remove
Animations.

The Action Script is removed.

InTouch HMI 2017 Update 3


12-24 Module 12 – Web Client

37. Click Add Animation.

The Animations list appears.


38. In the Animations list, select Hyperlink.

The Edit Animations dialog box appears.


39. In the Hyperlink details pane, Reference field, enter:
http://localhost/InTouchWeb/api/symbol/kpi

40. Click OK to close the Edit Animations dialog box.

Wonderware Training
Lab 27 – Using the Web Client 12-25

41. Save and close the Mixer symbol.


After the Symbol Editor closes, the default web browser is automatically refreshed and the KPI
button now appears in the Mixer symbol.

42. In the web browser, click the KPI button.


The KPI symbol appears without the Web Client menu and toolbar.

Even without the Web Client interface, the graphic supports zoom and pan.

InTouch HMI 2017 Update 3


12-26 Module 12 – Web Client

Wonderware Training

You might also like