Documentation
Documentation
Background
With the development of industrial and social economy, information
technology based on computers and high speed Internet is
becoming more and more mature and advanced; its application
range includes industrial manufacturing, import and export trading,
transportation, power energy, oil, chemical industry, metallurgy and
the everyday life, culture and entertainment of people etc.
Information technology is also gradually developing towards
automation and intelligence, promoting productivity revolution and
increasing people’s living standards.
The SCADA (Supervisory Control And Data Acquisition) system is
a data acquisition and monitoring system. It is a computer-based
automated production process control and management system that
can monitor and control the executing devices on-site in order to
realize functions including data acquisition, device control,
measurement, parameter control, various signal alarms and
generate charts and reports etc. The SCADA system has significant
effects for increasing the reliability, safety, economic benefits and
work efficiency of industrial production and management control; it
reduces personnel burden and labor, realizing automation and
modernization.
Since releasing its first inverter in 1995, Delta continues to
increase the reliability and precision of its products, and focused on
innovative development of inverters and the power quality control,
sensing, control and motion control fields. As its product lines
become more and more complete, Delta also integrated the PLC,
HMI, inverter, network communication devices, video and other
industrial automation products manufactured by itself to provide
comprehensive industrial automation solutions. With the gradual
promotion and global distribution of Delta’s own brand development
strategy, and to further increase Delta’s influence in the industrial
automation field, adapt to the customers’ need for Delta’s industrial
automation products and market development features, Delta
developed its own brand of SCADA system - - the Delta Industrial
Automation View system, abbreviated as DIAView.
Function features
Ø Based on the Windows operating system with wide, flexible
and reliable applications.
Ø Supports the communication and networking of domestic
and international mainstream PLC, DCS, PAC and IPC
devices.
Ø Based on the .NET Framework; uses WPF (Windows
Presentation Foundation) technology to display beautiful
images and fully supports the XML technology.
Ø Friendly user interface, rich graphic elements, easy
operations, easy configurations, easy usage and easy
maintenance.
Ø Distributed architecture with powerful scalability.
Ø Stable industrial communication design.
Ø Powerful alarm management.
Ø Easy-learning and easy-to-use scripting language
(VBScript).
Ø Highly efficient recipe management.
Ø Reliable user management.
2.1 Installation and configuration requirements
Configuration item Minimum HW/SW system requirement
CPU 2GHz or above
Memory 4GB or above
Hard disk 20GB or above
Display 1024 x 768 resolution or above
Windows 7 SP1 32bit/64bit (Professional/Ultimate/Enterprise)
Windows 8 32bit/64bit (Professional/Ultimate/Enterprise)
Windows 10 32bit/64bit (Professional/Ultimate/Enterprise)
Operation system
Windows Server 2008 R2 SP1 64bit
Windows Server 2012 64bit
Language: English,Simplified Chinese, Traditional Chinese
System Privilege Windows users must have administrator rights
Installation of Microsoft .NET Framework4.5.2 or above is
Execution Platform
required
Chromium-based browsers (version 45 or above) are required.
Browser
Chrome is recommended
Database SQL Server 2008 R2 or above
Note : Users must prevent the computer system from entering standby modes or
dormant state while DIAView runtime environment executes in order to prevent
"Unrecognized Encryption -dongle" exception.
2.2 DotNet installation
DIAView is developed based on the Microsoft .NET Framework
environment; .NET Framework4.5.2 or above must first be installed
before using DIAView. Installation steps are as follows (Taking
Windows7 Professional Edition as the example):
Once the installation program has started, it will enter the install
navigation interface; there is a list of buttons on the right of the install
navigation interface, when you move the mouse cursor onto one of
the buttons, the text of the button will change from white to yellow.
The functions of each button are as follows:
l Installation guide: Includes the system requirements for
installing DIAView, problems that might encounter during the
installation and the features of the new version.
Step 5: Press “-Next-” and the installation program will analyze the
installation environment and then the following window will appear:
Step 6: Click “-Install-” to start installing the DIAView main program;
the installation progress window will appear:
Step 7: When installation is complete, the dialog shown in the figure
below will appear; click the “-Finish-” button to complete the
installation of the DIAView software. If user checked the “-Start
DIAView-”checkbox, then the DIAView software will start when the “-
Finish-” button is pressed:
2.4 Install senselock driver
Installation steps are as follows (Using Windows7 Professional
Edition as the example):
Step 1: Start the computer and click the DIAViewSetup.exe file on
the disc to execute the installation program, as shown in the figure
below:
Step 4: Click the “-Next-” button to enter the program installation
stage; when installation is complete, the screen will appear as shown
in the figure below:
2.5 Install SQL server database
DIAView adds new "History Variable" function and optimize the query
efficiency, use new version of "History Variable" need install SQL
Server database and database version can't under the SQL Server
2008 Express R2. DIAView package has contain SQL Server 2008
R2 package(language version: en,x86 and x64), if user want to install
other language version or higher version, please go to microsoft
website(https://www.microsoft.com) to download. Installation steps
are as follows (Taking Windows7 Professional Edition as the
example):
Step 1: Right_click "Computer", click "properies", go to computer
system view, check the "system type", as shown in the figure below:
Step 2: Install SQL Server package in "sql" folder at DIAView
package, if your computer System type is 32-bit Operating System,
install package in "x86" folder, if your computer System type is 64-bit
Operating System, install package in "x64" folder, as shown in the
figure below:
Step 3: Click SQL Server package, go to installation view, as shown
in the figure below:
Step 5: Select "I accept the license terms" after read license and click
"Next", go to "Feature Selection" view, as shown in the figure below:
Step 13: Click "Close" after install success. If user want other
computer connect this SQL Server service, right_click computer, click
"Manage", go to Computer Management view, click "Services and
Applications" , click "SQL Server Configuration Manager", click "SQL
Server Network Configuration", select SQL Server service we
installed(default: SQLEXPRESS), check the status of "Named Pipes"
and "TCP/IP" is enabled, if status is disabled, right_click and click
"Enabled",as shown in the figure below:
Method 2: Click the DIAViewSetup.exe file on the disc to execute the
installation program. Select “DIAView” from the navigation window
that pops up, and then select “-Delete-” from the next screen that
appears; the system will automatically uninstall the program:
Ø Project
A project is a set of automated application system developed with
the DIAView software according to user requirement; it mainly
includes a collection of the development of automated monitoring
and control systems and its configuration information. A project
includes graphic window interface, IO communication, alarm,
variable and other parts, and the project developer can perform
centralized management for each part of the project.Project also can
be called "Engineering".
Variables are values of the project that can change at any time; they
are important participants for system data information handshakes.
Ø Window
The window is a core component of the DIAView software for users
to draw field simulation pictures, configure parameters and display
information. It is the basis to realize real-time visualization of the
DIAView software -- it provides various drawing elements including
basic graphic group, window controls group and advanced controls
group etc., system’s built-in graphics and the customized graphics
library that users can add on their own; it also provides windows that
allow configuring of image object properties, animations and events.
In the DIAView software, one windows is one screen.
Ø Property
In the DIAView software, properties describes the features or
characteristic information that all objects in a window; for example
name, size and background color etc
Ø Animation
Animation refers to the process of setting the properties of an
graphic object, including the size, color, rotation angle and position,
to change according to the changes in the variable data while the
project is executing.
Ø Event
An event refers to the process of specifying the properties of an
graphic object, including the size, color, rotation angle and position,
to change with mouse or keyboard operations.
Ø Operation variable
Refers to saving the operation record to the database when the
values of certain variables in the variable dictionary changed due to
user operations in order to query and check user operations.
Ø History record
Refers to saving the changing record of certain variable values in the
variable dictionary and defines the recording method for data
statistics and analysis.
Ø Security zone
Refers to dividing and setting the graphic objects, control units and
equipment etc. in the project to specific security levels so that only
users in that security level can access them. It is a method to control
user rights in order to guarantee the reliability and security of the
DIAView software execution.
Ø User
System operators and administrators with related operating
authorities set for the project development and execution. Different
authorities can be set for different users in order to achieve
specialization so that the DIAView software and execute securely.
The recipe ingredients are the main components of the recipe item.
The recipe ingredient is controlled by the engineering variables of
the
Ø User script
The user program of the DIAView software is mainly divided into
“condition program” , “time program” and "Global Function".
Global function refers to user can package the reusable script code,
and use it in other script.
Ø Global
Global refers to user can change content of text and image in
window by switch language.
Ø Project configuration
Project configuration includes the configuring of the database,
configuring of the execution screen and the configuration of the
starting screen. Users can achieve handshakes between real-time
data of the project and other commercial databases through
engineering configuration by setting related configurations of the
execution environment of the DIAView software
Ø Runtime
Runtime refers to dynamically running the project completed in the
development environment in the runtime environment according to
the development design requirements and configured parameters,
achieving real-time data acquisition of the system, dynamic display
of the screen, real-time response of commands, automatic display of
reports and manual dispatching and control in order to exert the
functions and effects of the various parts of the project.
4.2.1 Framework
Start the DIAView software development environment and enter the
main window of the system, as shown in the figure below:
Method 3: Press the “New” button in the toolbar on the starting page
of the DIAView software development environment to add a new
project.
Method 4: Right-click the mouse on the starting page of the DIAView
software development environment and then select “New” from the
right-click menu to add a new project.
Clicking the add project button adds a new project and related
information on project configuration, as shown in the figure below:
Name: Name defined for the project (required); the system will
choose a name by default but the user can also change it. The
project name customized by the user must comply with the naming
rules of the VB Script scripting language:
1. Composed of English letters,numbers,Chinese characters and
underscore,and the name must start with English letters or Chinese
characters.
2. No case Sensitive.
3. Spaces, periods, exclamation marks and special characters such
as @$#&*? etc. cannot be used in the name.
4. The length of the name cannot exceed 100 characters or 25
Chinese characters.
5. The name of the project cannot be repeated as other created
projects placed under the same project folder.
6. The name only supports three languages: Simplified Chinese,
Traditional Chinese and English.
Position: Specified the storage path of the project; press the button
to select the path.
Description: Allows users to define project-related explanation or
description information.
Project Template
When creating a new project, the "Select Project Template" window
will pop up, and the user can select the project template as needed,
as shown in the figure below:
Name: the name defined for the template (required). The current
project name will be used as the template name by default. You can
also customize it.
Template description: you can define the description or description
information of the project template.
4.2.3 Manage project
To manage project refers to performing centralized management of
the projects in the DIAView software to make it easier for users to
perform related operations to the projects. There are two methods to
manage the projects in the DIAView software: First is through the
starting page of the development environment and second is through
operating the function menu (please refer to “4.4.1 File menu”).
Start Page
Open the DIAView software development environment and the
starting page will be opened on the main interface by default. Project
item information will be opened if a project was previously being
developed, including project name, time of creation, modification
time, resolution, project path and project description information.
Operations such as add new, add, delete, clear, backup, restore and
set project as preset project etc. can be performed on the starting
page, as shown in the figure below:
Right-click menu can also be performed to do related operations on
the starting page, as shown in the figure below:
Introductions to the buttons and right-click menu item functions on the
start page:
1. Open: Opens the project selected from the project list on the
starting page; this can also be achieved by double-clicking the row of
project to be opened in the project list. Once the project is opened,
the project tree index will be displayed in the project window to the
right as shown in the figure below:
. New: Adds a new project; the created project will be added to the
2
project list on the starting page, and be opened in the project window.
Please refer to “4.2.2 New project”.
3. Add: Adds a project that already exists under the specified path
into the starting page project list. Click the “Add” button or right-click
menu to open the folder selection box:
4. Delete: Deletes the selected project on the starting page project
list. Click the “Delete” button or right-click menu to open the project
deletion selection box:
There are two delete options:
Delete list items of start page: Deletes the project information
from the starting page, but the project file is not deleted.
Delete project file and item, unrecoverable: Deletes the project
from the starting page list and also deletes the project file completely.
5.Modify project: Modify project name and description, click "Modify
Project" button or right-click menu to open the modifying project box:
6.Open project folder: Opens the folder where the project is located
7.Clean: Clears the project information on the starting page list. It will
be cleared if the project file was already deleted but still exists in the
project list.
8.Backup: Backup: Backs up the selected project. The backed up
project file will have the extension “.projectzip”, as shown in the figure
below:
1.Open project folder: Open the folder where the project is located.
2.Copy Project Path:Copy the project's path.
3.Statistics: Show the statistics about IO points and the variable
dictionary of the project.
4.Rename: Renames the project name.
5.Password: Sets a password for the project so that it can only be
opened when the correct password is entered.
Right-click the mouse on the root of the project in the project tree
index and then click “Password” to open the “Set and change
password” window, as shown in the figure below:
The meanings of each setting in the configuration window are as
follows:
Old password: Enter the original password of the project (if setting
the project password for the first time, the preset original password is
empty.
New password: Enter the new password.
Confirm new password: Enter the new password again.
Opening password-protected projects requires entering the
password, as shown in the figure below:
6.Save As Template: Save the project as a project template (see
"4.2.2 New project" for details)
7.Package: Group the user project and the run environment into
installation packages,Users can run projects directly after installation.
After the packaged project is installed, some project configurations
can be modified, and the configuration page opens to the path: "Start
Menu" - "Delta DIAView" - "Project Configuration"
Project directory tree,Right click on the project root node,Click
“Package”,Open “Packaging box” install page,as shown in the
figure below:
Project Path:The path to the project to be packaged (Selectable,
not editable)
Shortcut Name:The name of the shortcut generated after the
installation of the packaged file(Default is project name)
Install Language:Package the language for file installation(The
default is the current DVStudio language)
Output Directory:Package file generation path(The default is the
current user's Document\DIAViewSetup directory)
More Install Options:Open the custom installation options Settings
window
Pack:Package and pop up the progress display box
Select "More installation options",More installation options install as
shown in the figure below:
Install Location:The default is C:\Program Files(X86)
Shortcut Icon:Select the shortcut icon generated after the
installation of the packaged file (The default is an HMI icon)
License Agreement:Only valid RTF files can be uploaded,
otherwise the license agreement may be empty(The default is the
user protocol corresponding to the current DIAView)
Use default:Use default Settings,“Install Options”Return to the
default configuration
8.User Authorization: Bind the current project to the dongle,after
binding, the project can only run if the dongle to which it is bound is
inserted.
Ø Obtain the "User Authorization" license file
Use the "Computer fingerprint extraction tool" to extract
computer information
Computer fingerprint extraction tool:Is
"machinecodegenerator.exe" in C:\Program Files (x86)\DIAView path
Storage Path:Select the file storage path
Close:Close "computer fingerprint extraction tool"
Save All Saves all sketchpad and other configuration information of the current project,"A
Reverse cancels the previous operation starting from the last
Undo
operation.
Reverse cancels the previous operation starting from the last
Redo
“Undo.”
Enable the "Auto save" function to save all sketchpad configuration information of the current project
according to the set time:
4.4.1 File menu
The file menu is used to manage the project; its function items and
functions are as follows:
DongleKey
Number of clients
version
NO DongleKey(trial 1 client(C/S client or B/S client),unlimited
version) number of points,Trial of additional functions
standalone version 1 client(C/S client or B/S client)
N clients,Determined by DongleKey(all C/S
C/S version
clients)
B/S version N clients,Determined by DongleKey(the sum of
the number of C/S clients and B/S clients)
Step 2:Select the options of dongle and upgrade dongle respectively,
and click the merge upgrade button at the bottom right to upgrade the
dongle data point (unplug the dongle during the upgrade process), as
shown in the figure below:
Step 3:After merging and upgrading, a new 1500 no additional
functions encryption dog is generated for 5 clients. The upgraded
encryption dog can only be used once and then fails, as shown in the
figure below:
Step 4:Network version 5 client 1500 point no additional functions
dongle and 10 client upgrade dongle into the computer, in the
upgrade dongle window select the dongle and upgrade dongle to
upgrade the combination, as shown in the figure below:
Step 5:Merge and upgrade to generate a new 10 client 1500 point no
additional functions dongle, as shown in the figure below:
Step 6:Insert network version 10 client 1500 point no additional
functions dongle and additional function 1 upgrade dongle into the
computer, in the upgrade dongle window select the dongle and
upgrade dongle to upgrade the combination, as shown in the figure
below:
Step 7:Merge and upgrade to generate a new 10 client 1500 point
additional functions 1 dongle, as shown in the figure below:
The function of the start menu is mainly used for project management and layout operations of the
location, layer and arrangement of the graphic objects in the graphic interface development. The
availability of each button is determined by the selected graphic object and operations in the sketchpad.
When the mouse cursor is placed on top of the button, the system will display the reminder window with
the description of this button function below the mouse. The functions of each button are as follows:
Cut Cut one or multiple selected graphic objects from the sketchpad t
Copy Copy one or multiple selected graphic objects from the sketchpad
Paste Paste one or multiple graphic objects on the clipboard to the sket
Align Left Align two or more selected graphic objects in the sketchpad to th
Align Center Align two or more selected graphic objects in the sketchpad to th
Align Right Align two or more selected graphic objects in the sketchpad to th
Align Top Align two or more selected graphic objects in the sketchpad to th
Align Middle Align two or more selected graphic objects in the sketchpad to th
Align Bottom Align two or more selected graphic objects in the sketchpad to th
Distribute Vertical Distribute three or more selected graphic objects in the sketchpa
Distribute Horizontal Distribute three or more selected graphic objects in the sketchpa
Same Center Align two or more selected graphic objects in the sketchpad to th
Make two or more selected graphic objects in the sketchpad have
Same Width
the same width.
Make two or more selected graphic objects in the sketchpad have
Same Height
the same height.
Make two or more selected graphic objects in the sketchpad have
Same Size
the same width and height.
Group Groups the selected multiple graphic objects into a new graphic w
Bring to Front Move the selected graphic object at the top layer when there are
Send to Back Move the selected graphic object at the bottom layer when there
Bring Forward Move the selected graphic object up one layer when there are m
Send Backward Move the selected graphic object down one layer when there are
Rotate Clockwise Rotates the selected graphic object in the sketchpad 90 degrees
Rotates the selected graphic object in the sketchpad 90 degrees
Rotate Counter Clockwise
counterclockwise using the center of the graphic object as the or
Flip the selected graphic object in the sketchpad vertically using
Flip Vertical
the Xaxis of the center of the graphic object as the axis of symme
Flip Horizontal Flip the selected graphic object in the sketchpad horizontally usin
Enable Snap When enable snap function, draw and move objects by the grid.
Enable Pan When enable pan function, handshape tool will be displayed to m
The view menu is used to open the configuration windows including
the property window and project tree index etc. under the
development environment; its button functions are as follows:
The functions of the sketchpad right-click menu are as follows:
Command Description
1、Gallery introduction
4.14 Extended property window introduction
Extended property allows user to configure self-defined property
for group graphics,in this window,users can not only add or delete
extended property but also can rename, select type, set default
value, add description and relate script with the property in the
popups, as shown in the figure below:
5.1 Overview
IO communication refers to the DIAView software connecting to a
southbound equipment through specific communication protocols to
perform data acquisition and transmission. It has high reliability,
stability, instantaneity and powerful data processing capability.
Device Example
Siemens,Mitsubishi,Rockwell,Omron
etc.
Simulator Simulator
Modbus TCP
Modbus Serial RTU
Modicon
Modbus Serial ASCII
FINS TCP
FINS UDP
Omron
FINS ASCII
HostLink ASCII
Delta AS series:TCP、
RTU、ASCII
Delta
Delta AH series:TCP、
RTU、ASCII
Delta DVP series:TCP、
RTU、ASCII
Delta MC TCP、DIALink
PLC、DIALink
Mitsubishi FX Serial
Mitsubishi ProFX Serial
Mitsubishi Q Serial
Mitsubishi
Mitsubishi Q EtherNet
Mitsubishi FX EtherNet
S7300 TCP
Siemens S71200 TCP
S7300 MPI
S7200 TCP
S7200 PPI
S7200 Smart TCP
Simulator Simulator
DPM-C530 Ethernet
Delta Power Meter
DPM-C530 Serial
Rockwell Controllogix
Rockwell
Ethernet
ØWhen creating a new driver, you can quickly find the driver
through the retrieval function:
Step 1: Right-click on the “IODevice” node in the project
management area and select” New Device”; the menu selection in
Communication property:
Property Description
Step 3: Rename the IO variable name “Address” to “D0” and click the
button in the Address field to open the address property configuration
window to configure the address:
Parameter descriptions
Register type
Read/Write
Register type Mode Description Remark
Value type
BYTE Byte
UBYTE Unsigned byte
WORD Word
UWORD Unsigned word
DWORD Double word
UDWORD Unsigned double word
FLOAT Single-precision floating point
DOUBLE Double-precision floating point
STRING String
Character exchange
No Swap (01)
No Swap (0123) No exchange
No Swap (01234567)
Swap BYTE (10) Byte exchange (Word)
Swap BYTE (3210)
Swap WORD BYTE (1032) Byte exchange (DWord)
Swap WORD (2301)
Swap BYTE (76543210) Byte exchange (Double)
Swap WORD BYTE (10325476)
Swap DWORDBYTE (32107654)
Swap WORD (67452301)
Swap DWORD (23016745)
Swap DWORD (45670123)
Step 4: Select register type: “D:WORD R/W (D: Data register (WORD
R/W))”, unit number: 0, keep the default value for other items, as
shown in the figure below:
Step 5: Click the button in the【Variable】field to open the variable
browser and select the previously created internal project variables,
to complete the association mapping between the IO variables and
internal project variables:
Step 6: Use default values for the bits in other fields; this completes
the creation of an IO variable:
Register type:
Function Default
Register Description Property
code value
Analog value
4 Read only 4 Word
input
Expanded output
5 Read/write 21 Word
register
Expanded input
6 Read only 20 Word
register
Value type:
BYTE Byte
UBYTE Unsigned byte
WORD Word
UWORD Unsigned word
DWORD Double word
UDWORD Unsigned double word
FLOAT Single-precision floating point
DOUBLE Double-precision floating point
STRING String
Character exchange:
Step 4: Select register type: “3: Holding register (R/W)”, unit number:
4096, keep the default value for other items, as shown in the figure
below:
Step 5: Click the button in the "Variable" field to open the variable
browser and select the “Analog value" type variables:
Step 6: Use preset values for the bits in other fields; this completes
the creation of an IO variable D0:
Step 7: Create another IO variable Y0: The other steps are the same
as creating D0, only its "Address" field parameters are as shown in
the figure below:
Step 8: Complete the creation of the two IO variables D0 and Y0, as
shown in the figure below:
2、Creating IO variables in batches
Step 1: Click the “Batch Add " button on the IO variable configuration
window toolbar of the “Serial port device”:
Meanings of configuration items:
Step 3: Batch add 10 IO variables D1~D10, as shown in the figure
below:
Step 4: Associate the variables and set the bits in other fields; this
completes the batch creation of IO variables.
5.5.2 IO toolbar
1、 Add IO Variable
Double-click the created "device 0" to open the device IO variable
configuration window on the “IODevice” node in the project
management area.Click "Add" to add an IO variable named
"Address0" by default, as shown in the following figure:
2、 Insert IO Variable
In the IO variable configuration window, select the IO variable
"Address1", click "Insert", and insert a new IO variable "Address3"
above "Address1", as shown in the following figure:
3、 Delete IO Variable
In the IO variable configuration window, select the IO variable
"Address1", click "Delete" to delete "Address1", as shown in the
following figure:
4、 Batch Add IO Variables
In the IO variable configuration window, click "Batch Add" to add
multiple IO variables, as shown in the following figure:
5. Export IO variable table
Step 2: Select the tag file path and check "Create the corresponding
Variable in the Variable Dictionary":
Step 3: The tag in the XML file is imported successfully, and the
variable dictionary data is automatically generated and bound:
8、 Search
Several IO variables have been added in IO variable configuration
window. Enter "KeyWord" and click "Search". The IO variable
configuration window only displays IO variables that meet the
"keyword" filter criteria. When "KeyWord" is empty, all IO variables
are displayed.The keyword matches both name and address of IO
variable:
9、 Replace
Name replacement is to replace the name of an IO variable with
another name.
Step 1: Before replacement, use the keyword "D: 8" to retrieve the IO
variable names corresponding to addresses D: 8, D80, D81... D87 as
Address 8, Address 80, Address 81... Address 87, as shown in the
following figure:
Step 3: Configure a “Left-click” event for the “Stop” button, as shown
in the figure below:
Step 4: Configure a “Expression(E)” for the “Status value” text, as
shown in the figure below:
Step 7: The communication status of “Device0” is as follows after
clicking the “Stop” button:
Step 8: The communication status of “Device0” is as follows after
clicking the “Start” button:
5.8.1 Modicon
Modicon is the sub-brand of Schneider Electric,its Chinese
name is "Mo Di Kang".
DIAView software supports the communication of Modicon
PLC,the protocols include Modicon RTU,Modicon
ASCII,Modicon TCP.
Supporting communication network interface: Ethernet and
serial.
² Noted: Modicon address description,as shown in the table below:
Example 1:
Example 1:
Example 1:
Step 2: In the project management area, right click on "IO Device "node and
select "New Device".
Step 3: Select "Omron" →"FINS TCP" in the driver selection window, as
shown in the figure below:
Step 4: Configure the Omron FINS TCP communication parameters, as
shown in the figure below:
Step 5: Set "IP" in the "Base" as 192.168.1.5, set port number as 9420, as
shown in the figure below:
Step 6: Other options can be the default value, click "Test" button to test
whether the connection is successful.
Step 7: Click “Next” button to go to Omron FINS TCP specific configuration
interface, Source node: 65, Destination node: 5, other unchanged,as shown in
the figure below:
Network Address:
If there is only one local network, then the network numbers are all set to 0,
representing only one network. If there are multiple networks, in order to avoid
conflict, then you must specify different network number at all levels, the range
is 1-127.
Node Address:
In the same level of the network, the node number of each connection node
needs to be set as a different number, a node corresponds to a PLC. If it is an
Ethernet network, the node number is the last field of the IP address generally.
Unit Address:
In the same PLC, each module unit number is different from each other,
CPU unit number has always been 0, the rest of their own settings.
Step 8: Click “OK” button when all parameters have been configured and the
device with default name “Device0” will appear under “IO Device” node, and
open IO variable configuration window for Device0, as shown in the figure
below:
Step 9: Rename the newly-built IO device as "Omron_CSCJ" and complete
Omron FINS TCP driver communication configuration, as shown in the figure
below:
Step 10: Double click "IO Device" node to open IO device list window and
confirm that the device is added successfully, as shown in the following figure:
Ø Noted: FINS(CS/CJ):Omron address description is as shown in the table
below:
Default
Register Range Description
type
CIO_B 0.0~6143.15 Bool for example:CIO_B:0.15/BOOL
CIO_W 0~6143 Word CIO_W:6143/WORD
WR_B 0.0~511.15 Bool WR_B:511.15/BOOL
WR_W 0~511 Word WR_W:511/WORD
HR_B 0.0~511.15 Bool HR_B:0.15/BOOL
HR_W 0~511 Word HR_W:511/WORD
00000~44715(only read),AR_B:0.15/BOOL
AR_B 0.0~959.15 Bool
44800~95915(read/write),AR_B:959.15/BOOL
000~447(only read),AR_W:0/WORD
AR_W 0~959 Word
448~959(read/write),AR_W:448/WORD
DM_B 0.0~32767.15 Bool DM_B:0.15/BOOL
DM_W 0~32767 Word DM_W:511/WORD
EM_B 0.0~32767.15 Bool EM bank 0 to bank F: E0_0000000 to
3276715 to EF_0000000 to 3276715 like :
EM_B0:3276715,for
example:EM_B:0/1.15/BOOL
EM bank 10 to bank 18: E0_0000000 to
3276715 to EF_0000000 to 3276715
EM current bank: E0000000 to E3276715
EM bank 0 to bank F: E0_00000 to 32767 to
EF_00000 to 32767,like: EM_B0:32767,for
example:EM_W:0/1/WORD
EM_W 0~32767 Word
EM bank 10 to bank 18: E0_00000 to 32767
to E18_00000 to 32767
EM current bank: E00000 to E32767
TIM_PV 0~4095 Word TIM_PV:0/WORD
CNT_PV 0~4095 Word CNT_PV:0/WORD
IR_W 0~15 Word IR_W:0/WORD
DR_W 0~15 Word DR_W:0/WORD
5.8.2.2 FINS UDP
The equipment that current test environment requires is Omron
NX1P2.
If there is only one local network, then the network numbers are all
set to 0, representing only one network. If there are multiple
networks, in order to avoid conflict, then you must specify different
network number at all levels, the range is 1-127.
Node Address:
Unit Address:
In the same PLC, each module unit number is different from each
other, CPU unit number has always been 0, the rest of their own
settings.
Step 8: click the “OK” button when all parameters have been
configured and the device with the default name “Device0” will appear
under the “IO Device” node, and open IO variable configuration
window for Device0, as shown in the figure below:
Step 2: In the project management area, right click on "IO Device"
node and select "New Device":
Step 3: select "Omron" → "FINS ASCII" in the driver selection
window, as shown in the figure below:
Step 7:Click "Next",configure Omron FINS ASCII communication
parameters, as shown in the figure below:
Step 8: Click “OK” button when all parameters have been configured
and the device with the default name “Device0” will appear under the
“IO Device” node, and open IO variable configuration window for
Device0, as shown in the figure below:
Step 9: Rename the newly-built IO device as "Omron_FINS_ASCII"
and complete Omron FINS ASCII driver communication configuration,
as shown in the figure below:
Step 10: Double click "IO Device" node to open IO device list window
and confirm that the device is added successfully, as shown in the
following figure:
5.8.2.4 HostLink ASCII
The example that DIAView software communicates with
equipments by serial is as follows,using C-mode command:
Ø Creating communication between DIALink and Omron CJ2M
through serial port:
Step 6: click the “OK” button when all parameters have been
configured and the device with the default name “Device0” will appear
under the “IO Device” node, and open IO variable configuration
window for Device0, as shown in the figure below:
Step 7: Rename the newly-built IO device as "Delta AS MC TCP"
and complete Delta AS MC TCP driver communication configuration,
as shown in the figure below:
Step 8: Double click the "IO Device" node to open the IO device list
window and confirm that the device is added successfully, as shown
in the following figure:
5.8.3.2 Delta ES3 TCP
The DIAView software supports communication with the Delta ES3
TCP.
Step 6: click the “OK” button when all parameters have been
configured and the device with the default name “Device0” will appear
under the “IODevice” node, and open IO variable configuration
window for Device0, as shown in the figure below:
Step 7: Rename the newly-built IO device as "Delta AS MC TCP"
and complete Delta ES3 TCP driver communication configuration, as
shown in the figure below:
Step 8: Double click the "IO Device" node to open the IO device list
window and confirm that the device is added successfully, as shown
in the following figure:
5.8.3.3 Delta AS TCP
The DIAView software supports communication with the Delta AS.
Step 6: click the “OK” button when all parameters have been
configured and the device with the default name “Device0” will appear
under the “IO Device” node, and open IO variable configuration
window for Device0, as shown in the figure below:
Step 7: Rename the newly-built IO device as "Delta AS TCP" and
complete Delta AS TCP driver communication configuration, as
shown in the figure below:
Step 8: Double click the "IO Device" node to open the IO device list
window and confirm that the device is added successfully, as shown
in the following figure:
5.8.3.4 Delta AS Serial RTU & ASCII
The example that DIAView software communicates with equipments
by serial port is as follows:
Step 6: click the “OK” button when all parameters have been
configured and the device with the default name “Device0” will appear
under the “IODevice” node, and open IO variable configuration
window for Device0, as shown in the figure below:
Step 7: Rename the newly-built IO device as "AH Modbus TCP" and
complete AH Modbus TCP driver communication configuration, as
shown in the figure below:
Step 8: Double click the "IO Device" node to open the IO device list
window and confirm that the device is added successfully, as shown
in the following figure:
5.8.3.6 AH Modbus Serial RTU & ASCII
The example that DIAView software communicates with equipments
by serial port is as follows:
Step 6: click the “OK” button when all parameters have been
configured and the device with the default name “Device0” will appear
under the “IO Device” node, and open IO variable configuration
window for Device0, as shown in the figure below:
Step 7: Rename the newly-built IO device as "DVP MC TCP" and
complete DVP MC TCP driver communication configuration, as
shown in the figure below:
Step 8: Double click the "IO Device" node to open the IO device list
window and confirm that the device is added successfully, as shown
in the following figure:
5.8.3.10 DIALink PLC
The DIAView configuration software supports communication with
the DIALink PLC server.
The example of configuring IO communication with DIALink PLC
server in DIAView configuration software is as follows:
Ø Creating communication between DIAView software and
DIALink PLC server:
Step 1: In the project window tree directory, the "IODevice" node
right-click on the "New Device"
Step 2: In the select drive window, select "Delta" to "DIALink PLC":
Step 3: Configuring DIALink PLC communication parameters, the
default values can be kept as follows:
The meaning of each configuration item in the window:
Computer: IP or the full name of the computer.
Port:The default value is 9000.
CommunicationFormat: Default Json format, fixed.
Step 4: Each parameter configuration is completed by clicking the
"confirm" button. The default name of the device will appear under
the "IODevice" node of the project tree directory:
Step 5: Rename the new IO communication device to "DIALinkPLC"
and complete the DIALink PLC driver communication configuration:
Step 6: The new address or the modified address is as follows:
Step 7: Batch new address, as follows:
Effect picture:
Step 2: In the project management area, right click on “IO Device
“node and select “ New Device “, select " Mitsubishi " →“Mitsubishi
FX Series” in the driver selection window, as shown in the figure
below:
Step 3: Configure FX3U, Format 1 communication parameters, as
shown in the figure below:
Step 4: Click the button on the right side of "Serial Port" in the
"Basic" to open the "Serial Port Parameter Setting" window, set the
serial port communication parameters: "9600, 7, e, 1", and the
communication port is COM6 (it can be seen in the Device Manager
that the currently assigned serial communication port is COM6), as
shown in the following figure:
Step 5: Click "OK" button when serial communication parameters
have been all configured, return to the window of communication
parameter configuration to set communication parameters and fault
processing parameters, the device address should be consistent
with PLC station number, should be all set to "2". Other parameters
can be the default value, as shown in the figure below:
Step 6: Click “next” button to open “Mitsubishi FX Serial”to set
communication parameters, as shown in the figure below(Check 'FX-
485-PC-IF' for RS485 communication):
Step 7: Click the "OK" button when all parameters have been
configured and the device with default name will appear under “IO
Device” node of the project tree directory:
Step 8: Rename the newly-built communication device as
"Serial_Device", complete the serial port driver communication
configuration, as shown in the figure below:
Ø Noted: Mitsubishi FX3U address description, as shown in the
table below:
Register Range Default type Description
X 0.0 - 377.15 bool Input register
Y 0.0 - 377.15 bool Output register
M 0.0 - 7679.15 bool Auxiliary register
S 0.0 - 4095.15 bool Status register
SM 8000.0-8511.15 bool Special auxiliary
register
TS 0.0 - 511.15 bool Counter contact
register
CS 0.0 - 2047.15 bool Counter contact
register
TN word Timer register
0 - 511
CN16 word
0 - 199 16 bit counter
register
CN32 word
200 - 255 32 bit counter
register
D word Data register
0 - 7999
Step 7: Click the "OK" button when all parameters have been
configured and the device with default name will appear under “IO
Device” node of the project tree directory.
Step 8: Rename the newly-built IO communication device as
"Programming_Port_Device" and complete programming port driver
communication configuration, as shown in the figure below:
CN32 word
200 - 255 32 bit counter
register
Step 7: Click the “OK” button when all parameters have been
configured and the device with the default name “Device” will appear
under the “IODevice” node:
Step 8: Rename the newly-built IO communication device as
"Serial_Device" and complete the serial port driver communication
configuration as shown in the figure below:
Step 2: In the project management area, right click on “IODevice”
and select “New Device”, select “Mitsubishi FX EtherNet” in the
driver selection window, as shown in the figure below:
Step 3: Configure universal FX3UC, ASCII communication
parameters, and set the "IP" as: 192.168.1.201 in the “Base” setting,
set the port number as: 1500, as shown in the figure below:
Step 4: Other parameters can be the default, click “ Test “button to
test the connection
Step 7: Rename the newly-built IO communication device as
"Ethernet_Device" and complete Ethernet driver communication
configuration, as shown in the figure below:
CN16 word
0 - 199 16 bit counter
register
CN32 word
200 - 255 32 bit counter
register
Step 2: Right-click on the “IODevice” node in the project
management area and select “New Device”
Step 3: Select “Siemens” →“S7300 TCP” in the menu selection, as
shown in the figure below:
Step 5: Set the IP address in the base setting as: 192.168.1.2, set
“Port” as: 102, click“test”button to test the connection ,as shown in
the figure below:
Step 6: Click the “OK” button when all parameters have been
configured and the device with the default name “Device” will appear
under the “IODevice” node,as shown in the figure below:
Ø Noted: Siemens S7300 TCP address description(different CPU
models and ranges), as shown in the table below:
Register Range Default type Description
Step 2: Right-click on the “IODevice” node in the project
management area and select “New Device”
0~ 65534
Output register
QW WORD
Step 5: Click the "OK" button when the parameters have been
configured to return to communication parameter configuration
window and set communication and troulbeshooting parameter.
"DeviceAddress " should be the same with DPM-C530 station
number,set it as "2", other option can be default, as shown in the
figure below:
Step 6: Click the "OK" button when all parameters have been
configured and the device with default name "Device" will appear
under “IODevice” node of the project tree directory:
Step 7: Rename the newly-built IO communication device as
"DPM_C530_Serial" and complete Ethernet driver communication
configuration, as shown in the figure below:
5.8.6.2 DPM-C530 Ethernet
DIAView software supports the communication of the
equipment based on MODBUS RTU communication protocol
standard by Ethernet to transform delta IFD9506 to RS-485.
Step 5: Click the "OK" button when the parameters have been
configured and the device with default name "Device" will appear
under "IODevice" node of the project tree directory, as shown in the
figure below:
Step 6: Rename the newly-built IO communication device as
"DPM_C530_Ethernet" and complete Ethernet driver communication
configuration, as shown in the figure below:
5.8.7 Rockwell
DIAView software supports the communication of Rockwell PLC.
Step 2: In the project management area, right click on “IODevice “
node and select “ New Device “,select "Rockwell" →"Rockwell
ControlLogix Ethernet" in the driver selection window, as shown in
the figure below:
Step 3: Configure the ControlLogix Ethernet communication
parameters and set the "IP" in the base settings as 192.168.1.15, set
the port number to: 44818, as shown in the figure below:
Step 4: Click the "OK" button when all parameters have been
configured and the device with default name "Device" will appear
under “IODevice” node of the project tree directory:
Step 5: Rename the newly-built IO communication device as
"Ethernet_Device" and complete Ethernet driver communication
configuration, as shown in the figure below:
WORD INT 2
DWORD DINT 4
FLOAT REAL 4
STRING STRING
4
BOOL BOOL
BYTE SINT 1
WORD INT 2
FLOAT REAL 4
STRING STRING 4
5.9 OPC
DIAView software supports OPC relative protocol.
5.9.1 OPC DA
DIAView supports communication with OPC server
The IO communication between DIAView configuration software
and OPC server is as follows:
Ø Creating the communication between DIAView software and
OPC UA Server:
Step 1: Configure “AH500 OPC Server”, read data in the address of
AH500, as shown in the figure below:
Step 2: In the project management area, right click on “IODevice
“node and select “ New Device “, Select “OPC” in the "Driver
Selection" window“OPC” → “OPC DA”, as shown in the figure below:
Step 3: Configure the common communication parameters or keep
the default values, as shown in the figure below:
Step 4: Click “next”, appear “OPC DA” configuration window, Select
"Delta.AHModbus EthernetDA.1" in the drop-down list of the "OPC
server" option and keep other items the default value:
The meaning of each setting are is as follows:
OPC server : Select OPC server.
Computer (Null(Empty) value represents the local computer):
Install the OPC server computer. If the OPC server and the DIAView
configuration software are installed on the same computer, it will be
empty; if the OPC server is installed on the LAN or other computer,
then click "..." button to select remote computer name.
Synchronization: If the data is wrong, use it again
Using hierarchical namespace:Whether this function is checked
or not determines the display mode of IO variable "address" under
the drive - if checked, it will be displayed according to the file
directory, and if not checked, the variable path will be displayed
directly:
Checked effect:
Unchecked effect:
Step 5: The batch addition function is added in the new version. The
item "IO Name" needs to be filled in and cannot be blank, as shown
in the figure below:
Step 6: You can test (When adding an address, if you want to test,
please save it),the following figure:
Step 7: Click the "OK" button after all the configuration is done,a
device with the default name will appear under the "IO
Communication" node of project directory tree, as shown in the
figure below:
5.9.2 OPC UA
DIAView supports communication with OPC UA server.
The IO communication between DIAView configuration software and
OPC UA server is as follows:
ØCreating the communication between DIAView software and
Delta AH500 OPC Server:
Step 1: Install "OPC UA Local Discovery Server 1.02" of OPC foundation
to discover the server. Find the path: "Installation package" - "OPC" -
"LDS".
Step2:Right click the "IO Device" node in the tree directory of the project
window, and select OPC UA, as shown in the figure below:
Step3:Configure OPC UA communication parameters, as shown in the
figure below:
Step4:Enter the server address in the "ServerUrlNode" box, click the
"Select" button to display different security policy nodes, select the required
security policy and complete the configuration, as shown in the figure
below:
Step5:After the IO communication device is successfully created, click
"Add" on the variable configuration page and select the data points to be
read by the server, as shown in the figure below:
Step6:After the data point is configured successfully, click the "Test" button
to read the current data value, as shown in the figure below:
ØCommunication mode verification:
1、Certificate verification
In the case of certificate verification, the certificates of the server and the
client need to trust each other to communicate:
DIAView OPC UA Client
1)Create Certificate
When the client does not have a certificate, you can manually create a
certificate. Click the "Create Certificate" button:
The initial status of the create certificate page is gray,click the "Edit" button
to configure the hosting program successfully, and then you can create the
certificate. The parameter configuration is shown in the figure below:
The storage location of the certificate generated by "Store Path" is under the
"MachineDefault" folder by default.
The default value of "Application Name" is UA local discovery server, and
the name "DIAView OPC UA" used in the test is shown in the figure.
The default value of "Application URI". Check the check box on the right.
Double click the content area to modify it manually.
The default value of "Subject Name". Check the check box on the right.
Double click the content area to modify it manually.
The default value of "Domains" (computer name). Check the check box on
the right. Double click the content area to modify it manually.
Configure Managed Application:
Click "OK" to generate the certificate after the configuration is completed in
the create certificate page.
2)Browse Certificate
Click the "Browse Certificate" button:
On the certificate list page, select the required certificate and right-click
"view":
Display details of the selected certificate; When the client establishes
communication with the server, and the server cannot automatically obtain
the client certificate, you need to export the certificate and manually import
the server trust list:
3)Import Certificate
When the server certificate needs to be trusted, you can choose to import the
certificate and click the "Import Certificate" button:
Select the certificate to be trusted, click OK, and then import:
The imported certificate is stored in "RejectedCertificates", which is a denial
of trust; Take out the certificates that need to be trusted and store them in the
folders of "MachineDefault", "UA Applications" and "UA Certificate
Authorities":
Server
1)Certificate trust:
The server selects the trusted client, the third-party OPC UA server, take
KEPServer as an example, as shown in the figure below:
2、User authentication
In the case of user authentication, when the server has no user
authentication, the client can log in anonymously; When the server has user
authentication, the client needs to enter the correct user name and password:
DIAView OPC UA Client
When there is no user authentication on the server, do not check user
configuration, and the input box is gray; When the server has user
authentication, check the user configuration and enter the correct user name
and password in the input box:
5.9.3 OPC UA AX
OPC UA drive for Delta AX-8 series PLC.
ØEstablish OPC UA communication between DIAView
configuration software and AX-8 series PLC:
Driving method please refer to“5.9.2 OPC UA”
5.10 Simulator
DIAView software supports the communication with simulator,
simulator can offer data with regular changes when there is no filed
data.
5.10.1 Simulator
The IO communication between DIAView software and stimulator is
as follows:
Simulation parameters:
Register Range Description
Increase 0~63 Increase
Decrease 0~63 Decrease
Random 0~63 Random
Sine 0~63 Sine wave
Square 0~63 Square wave
Triangle 0~63 Triangle wave
Memory 0~63 Memory, read-write
Step 4: Click the “OK” button when all parameters have been
configured and the device with the default name “Device0” will appear
under the “IODevice” node, as shown in the figure below:
Step 5: Double click "Device0" , add an address and configure
address parameters, as shown in the following figure:
The meanings of each configuration in the window are as follows:
Step 6: Click the “OK” button when all parameters have been
configured and the address with default name "Address" will appear
under the "Device0” window,no retain by default,as shown in the
figure below:
Ø Double-click the created “variable group” sub-node and open the
variable operation window to perform operations including adding,
inserting, deleting, bach add,import,and export of variables, as shown
in the figure below:
Ø Right-click the created variable sub-node to perform operations
including “New Variable Group”,"Import Variable Group","Export
Variable Group", “Copy”,“Delete”,"Rename", “Paste” etc. (file must be
saved before copying), as shown in the figure below:
Edit variables directly under “variable dictionary”
Ø Users can also double-click on the “variable dictionary” node to
open the variable configuration window without adding a variable
group, then operations such as adding, deleting, copying, pasting,
cutting, importing,exporting and search of variables can also be
performed.
6.3 Variables
System variables: Fixed variables built-in the system; the DIAView
has 17 system variables which can be used directly by the users:
Variables are values that can change at any time in a project; they
are important participants for the information interaction of the
system. Variable information in the DIAView is as follows:
1、 Add Variable
Double-click "Variable Dictionary" node or double-click the created
variable group node to open the variable configuration window.Click
"Add" to add an variable namde "Variable" by default,as shown in the
following figure:
2、 Insert Variable
In the variable configuration window, select the variable
"Variable1",click "Insert", and insert a new variable "Variable3" above
"Variable1", as shown in the following figure:
3、 Delete Variable
In the variable configuration window, select the variable
"Variable1",click "Delete" to delete "Variable1", as shown in the
following figure:
4、 Batch Add Variable
In the variable configuration window, click "Batch Add" to add multiple
variables,as shown in the following figure:
5、 Export Variable
Step 1: Under project directory tree, double-click "Variable
Dictionary" node or double-click the created variable group node
to open the variable configuration window, export variable table,
as shown in the following figure:
Step 2: Select file storage path and save variable table:
6、 Import Variable
DIAView configuration software can import variables through Excel
file formats, the variables in the import file must be correct and valid
data.
Import From Excel
7、 Search
Several variables have been added in the variable configuration
window. Enter "KeyWord" and click "Search". The variable
configuration window only displays variables that meet "keyword"
filter criteria. When "KeyWord" is empty, all variables are
displayed.The keyword matches variable name:
6.5 Variables usage browsing
The variable usage browser refers to the window used to view the
status of all variable references in the variable dictionary. It can be
used to view whether a variable is referenced and information on the
reference path.
2. In the tree index to the left, if the round symbol in front of the
variable displays as “yellow”, it means that this variable is referenced.
If it is “gray,” it means that it is not yet referenced.
3. Select the variable to view from the tree index to the left, and the
variable reference display window on the right will display all objects
in the project that uses that variable. They are displayed using an
expanded tree index in order for users to pinpoint the objects that
actually uses this variable.
4. Click the pull-down button to filter the variables, as shown in the
figure below:
6.6 Variables substitution
Variable substitution refers to substituting a referenced variable in
the project into another variable.
1.Analog
Click the drop-down list on the right of Analog,and the option of
display value of analog pops up,as shown in the figure below:
² KeepPreviousValue:In the event of a communication failure,the
variable displays the previous value.
² 0:In the event of a communication failure,the variable displays
0.
² -9999:In the event of a communication failure,the variable
displays -9999.
2.Digital
Click the drop-down list on the right of Digital,and the option of
display value of analog pops up,as shown in the figure below:
² KeepPreviousValue:In the event of a communication failure,the
variable displays the previous value.
² True:In the event of a communication failure,the variable
displays True.
² False:In the event of a communication failure,the variable
displays False.
3.String
Click the drop-down list on the right of String,and the option of
display value of analog pops up,as shown in the figure below:
² KeepPreviousValue:In the event of a communication failure,the
variable displays the previous value.
² ????:In the event of a communication failure,the variable
displays ????.
6.9 Variables browser
The variable browser is the window that displays all variables in the
"Variable dictionary”; many functions in the DIAView project need to
use variables. For example, configurations such as recipes and
variable operations etc. need associated variables, so “Variable
Browser” can be opened to search for the variable that needs to be
used, as shown in the figure below:
Step 2:Edit variable, press the button and the variable editor
window will pop-up, which allows you to perform variable operations:
Step 3:Variable type filter, the background of the button will change to
blue when selected ,which means display
all this type of variables in the variable dictionary; when it is not
selected, it means do not display this type of variables: a. Only
browse “Analog value”
b. Browse “Analog value” and “Digital value”
Step 4:Search variable, enter the variable
name keyword in the input frame to search for variables in real-
time.
6.10 Expressions
Expressions are meaningful arrangement method combinations of digits,
operators, digital grouping symbols (brackets etc.) and variables used to
determine a value.
Expressions are used for configuring animations and events in the DIAView
software project and writing user program scripts etc. Operations such as logical
operations, arithmetic operations and relational operations and performed through
expressions to generate a new result for the program to use in order to satisfy the
configuration needs of project animations, events and scripts, and achieve certain
functions in the project.
Common operators used in expressions:
^ power 5^2 25
Logical “Not”
operator operations
(performs
logical Not 39>10 False
Not negation
Not 10>39 True
operations to
the
expression to
the right)
“And”
operations (if
the conditional
operations of
both sides of
the And
And operator are 39>10 And 8>10 False
valid
simultaneously,
it
will return
True; or else it
will return
False)
Or “Or” operations 39>10 Or 8>10 True
(if the
conditional
operations of
both sides of
the Or
operator are
invalid
simultaneously,
it will return
False; or else it
will return
True)
1 Xor 1
False
0 Xor 1
True
Xor “Xor” 1 Xor 0
operations True
1 Xor 1
False
0 Eqv 0 True
0 Eqv 1 False
Eqv “Equivalent”
operations 1 Eqv 0 False
1 Eqv 1 True
0 Imp 0 True
Conditional expression editing window used for configuring animations and
conditional programs:
The meanings of each item in the window are as follows (the “Variable
dictionary” node is selected in the figure):
1. Project object tree index window: Includes objects such as system variables,
project variable dictionary, alarm and communication etc.
2. System function tree index window: Includes system functions.
3. Object list: Display area of the list of variable and other objects; double-clicking
an object allows it to be used.
4. Object properties list (this list is displayed according to the object selected): The
display area of the object property list; double-clicking an object property allows
it to be used.
5. Expression editing window: Allows editing of expressions.
6. Expression operator and digital button area: Selected operators and digits etc.
can be used.
7.1 Overview
Graphical interface development refers to draw vividly field
facilities, equipment, site structure and instruments etc. on the
DIAView, forming a stimulation picture of the industrial field. It can
even configure and connect data acquisition equipments such as
field equipment and instruments to display the data on the window in
real-time, making it easy for workers to monitor the field status.
Simulator switches and controllers etc in the window interface can
also be used to transmit commands and control field equipment .
After clicking “New Window”, the system will generate a window sub-
node under the “Window” node using a default name, and the new
window will be opened in the sketchpad work area, as shown in the
figure below:
Right click the "Window" node in the tree directory of the project
window, and click the "New Window From Templates" item in the
right-click menu, as shown in the figure below:
Right click the "window" node in the tree directory of the project
window, and click the "new window group" item in the right-click
menu, as shown in the figure below:
After clicking “New Window Group”, the system will generate a
window sub-node under the “Window” node using a default name, as
shown in the figure below:
4.Export window:Export the window to the specified location,
select the window node, right-click, and click "Export Window" in the
right-click menu.
6.Paste:Paste the copied window under the window node, select the
window node, right-click, and click Paste in the right-click menu.
Right click the "Window" node in the tree directory of the project
window, and click the "Manage Window Templates" item in the right-
click menu, as shown in the figure below:
2.Close window:
There are several ways to close a window:
Method 1: To close an opened window in the sketchpad work area,
simply click the“ ”to the right of the window name:
Method 2:In the sketchpad work area, select the closing method (3
types) from the field to the right of the opened window:
1. Close: Closes the current window
2. Close All But This: Closes all other windows besides the current
window
3. Close All: Closes all windows
3.Copy window:
Select the window node to copy in the project window tree index
and right-click on it, and the select the “Copy” item from the right-click
menu, completes the copy window,as shown in the example in the
figure below:
If users want to paste it,click the right-key at the "Window" root
node,select the "Paste" item from the right-click menu,as shown in
the figure below:
4.Delete window:
Select the window node to delete from the project window tree
index and right-click on it, then select the “Delete” item from the right-
click menu to delete the window:
5.Rename window:
Select the window node to rename in the project window tree index
and right-click on it, and the select the “Rename” item from the right-
click menu. The window name will become an editable status and just
input the new window name, as shown in the example in the figure
below:
8.Canvas:
The canvas where users draw and arrange the size, location and
layer of graphical controls. It also supports many auxiliary operations,
such as adding and changing selected controls, previewing locations
of dragged controls, limiting boundaries of moved controls, and auto
adjustment the offset value of the visiable work area etc.
7.2.1.3 Window group operation
In DIAView configuration software, windows of different types and
purposes can be grouped and managed. Window group operation is
the operation of the current grouping.
Ø Size: Sets the width and height (unit: pixels) of the window.
7.2.2.1 Web window root node
In the DIAView, windows are core components to perform field
stimulation picture drawing, parameter configuration and data
display; it is the basis to achieve DIAView visualization.
1.Steps to add window:
Right-click on the “Web Window” node in the project window tree
index and then click the “New Web Window” item in the right-click
menu, as shown in the figure below:
After clicking “New Web Window”, the system will generate a window
sub-node under the “Web Window” node using a default name, and
the new window will be opened in the sketchpad work area, as
shown in the figure below:
2.Add new window group steps: The window group is a unit to
perform grouped management of windows; group management can
be performed to the different types and uses of windows in the
project.
Step 1:Right-click on the “Web Window” node in the project window
tree index and then click the “New Web Window Group” item in the
right-click menu, as shown in the figure below:
Step 2:After clicking “New Web Window Group”, the system will
generate a window sub-node under the “Web Window” node using a
default name, as shown in the figure below:
Method 2:In the sketchpad work area, select the closing method (3
types) from the field to the right of the opened window:
1. Close: Closes the current window
2. Close All But This: Closes all other windows besides the current
window
3. Close All: Closes all windows
3.Copy window
Select the window node to copy in the project window tree index
and right-click on it, and the select the “Copy” item from the right-click
menu, completes the copy window,as shown in the example in the
figure below:
If users want to paste it,click the right-key at the "Web Window" root
node,select the "Paste" item from the right-click menu,as shown in
the figure below:
4.Delete window:
Select the window node to delete from the project window tree
index and right-click on it, then select the “Delete” item from the right-
click menu to delete the window:
5.Rename window
Select the window node to rename in the project window tree index
and right-click on it, and the select the “Rename” item from the right-
click menu. The window name will become an editable status and just
input the new window name, as shown in the example in the figure
below:
² Size: Sets the width and height (unit: pixels) of the window.
7.3 Graphic universal properties
All graphic objects have shared properties including names,
coordinates, sizes and display etc., and some graphic objects have
their own unique properties (graphic properties listed in section 7.5
and 7.6 are unique properties of those graphics). Universal
properties of graphic objects in the DIAView software are as follows:
Naming rules:
(4) The length cannot exceed 200 English letters and cannot
exceed 25 Chinese characters.
(5) Cannot be the same as the name of the window where the
graphic object is located.Cannot be the same as the name of the
other objects in the same window.
Graphic introduction:
F The figure above is a straight line under editing status; press the
stright line with the mouse under non-editing status to enter the
editing status.
F Points 1-8 in the figure are the tensile points to adjust the graphic
size; 9 is the rotation point and 10 is the center.
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points.
Straight line properties
² For property settings please refer to the section “7.3 Graphic
universal properties”.
7.4.2 Rectangle
Graphic introduction:
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points.
Rectangle properties
² For property settings please refer to the section “7.3 Graphic
universal properties”.
7.4.3 RoundedRectangle
Graphic introduction:
F The figure above is a selected rounded rectangle; click the mouse
on the rounded rectangle when under the not selected status to
enter the selected status.
F Points 1-8 in the figure are the tensile points to adjust the graphic
size; 9 is the rotation point and 10 is the center, 11 and 12 are the
adjustment points to adjust the shape of the round angle.
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points.
Rounded rectangle properties
² Arc of the horizon: Sets the ratio between the radius of the round
angle and the width of the graphic (value range: 0 ~ 100).
² Arc of the vertical: Sets the ratio between the radius of the round
angle and the height of the graphic (value range: 0 ~ 100).
² For other property settings please refer to the section “7.3 Graphic
universal properties”.
7.4.4 Ellipse
Graphic introduction:
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points.
Ellipse properties
² For property settings please refer to the section “7.3 Graphic
universal properties”.
7.4.5 Polyline
Ø Open the window interface and click on “Toolbox” → “Basic
Graphics” → “Polyline” in the tools window to the left; the toolbar
is as shown in the figure above.
Ø Move the mouse to the working area of the window, select a
starting point and click the mouse. Move the mouse to another
point and left-click the mouse (the polyline is drawn at this point),
left-click the mouse to generate a polyline point of the polyline
and draw polyline points according to your needs. If press the
shift key while moving the mouse, it would be allowed to draw the
polyline with mutiples of 15°. Double-click the left mouse button to
finish the drawing of a polyline and generate the polyline.
Ø Just repeat the steps above if another polyline needs to be drawn.
Graphic introduction:
F The figure above is a selected polyline; click the mouse on the
polyline when under the not selected status to enter the selected
status.
F Points 1-8 in the figure are the tensile points to adjust the graphic
size; 9 is the rotation point and 10 is the center.
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points.
F The figure above is an adjustable polyline; double-click the mouse
on the polyline when under the unadjustable status to enter the
adjustable status.
F In figure, 1 is the starting point, 2 and 3 are the polyline points and
4 is the ending point; when the mouse is moved on top of a point,
the mouse cursor will change to“ ”。Press and hold the left
mouse button and move the position of the point to adjust the
shape of the polyline.
Polyline properties
² For property settings please refer to the section “7.3 Graphic
universal properties”
7.4.6 Polygon
Ø Open the window interface and click on “Toolbox” → “Basic
Graphics” → “Polygon” in the tools window to the left; the toolbar
is as shown in the figure above.
Ø Move the mouse to the working area of the window, select a
starting point and click the mouse. Move the mouse to another
point and left-click the mouse to draw one side of the polygon (the
polygon is drawn at this point), draw the inflections according to
the shape of the polygon required. Every time the left mouse
button is pressed, the inflection of one side will be drawn. Double-
click the left mouse button to end the drawing of a polygon and
generate the polygon.
Ø Just repeat the steps above if another polygon needs to be drawn.
Graphic introduction:
F The figure above is a selected polygon; click the mouse on the
polygon when under the not selected status to enter the selected
status.
F Points 1-8 in the figure are the tensile points to adjust the graphic
size; 9 is the rotation point and 10 is the center.
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points.
F The figure above is an adjustable polygon; double-click the mouse
on the polygon when under the unadjustable status to enter the
adjustable status.
F In the figure, 1 is the starting point, 2 and 3 are the inflection points
and 4 is the ending point; when the mouse is moved on top of a
point, the mouse cursor will change to “ ”.Press and hold the
left mouse button and move the position of the point to adjust the
shape of the polygon.
Polygon properties
² For property settings please refer to the section “7.3 Graphic
universal properties”.
7.4.7 BezierCurve
F The figure above is a selected arc; click the mouse on the arc
when under the not selected status to enter the selected status.
F Points 1-8 in the figure are the tensile points to adjust the graphic
size; 9 is the rotation point and 10 is the center.
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points.
F The figure above is an adjustable arc; double-click the mouse on
the arc when under the unadjustable status to enter the adjustable
status.
F Points 1 and 2 in the figure are adjustment points to adjust the
length of the arc; when the mouse moves on top of a point, the
mouse cursor will change to“ ”,Press and hold the left mouse
button and drag the position of the adjustment point to adjust the
length of the arc.
Arc properties
² Starting angle: Sets the starting angle of the arc length (unit:
degrees).
² Scan angle: Sets the ending angle of the arc length (unit: degrees).
² For other property settings please refer to the section “7.3 Graphic
universal properties”.
7.4.10 Arch
Ø Open the window interface and click on “Toolbox” → “Basic
Graphics” → “Arch” in the tools window to the left; the toolbar is as
shown in the figure above.
Ø Move the mouse to the working area of the window, select a
starting point and press the left mouse button and drag the mouse
towards the bottom-right (the arch is already drawn at this point).
After releasing the left mouse button, the drawing of an arch is
complete, and an arch will be generated.
Ø Adjusting the angle of the arc: Double click the arc to enter the
adjustable status; place the mouse on any of the yellow diamond
adjustment point, press and hold the left mouse button to drag the
adjustment point to change the angle of the arc.
Ø Just repeat the steps above if another arch needs to be drawn.
Graphic introduction:
F The figure above is a selected arch; click the mouse on the arch
when under the not selected status to enter the selected status.
F Points 1-8 in the figure are the tensile points to adjust the graphic
size; 9 is the rotation point and 10 is the center.
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points.
F The figure above is an adjustable arch; double-click the mouse on
the arch when under the unadjustable status to enter the adjustable
status.
F Points 1 and 2 in the figure are adjustment points to adjust the
angle of the arch; when the mouse moves on top of a point, the
mouse cursor will change to“ ”. Press and hold the left mouse
button and drag the position of the adjustment point to adjust the
angle of the arch .
Arch properties
² Starting angle: Sets the starting angle of the fan-shape angle (unit:
degrees)
² Scan angle: Sets the ending angle of the fan-shape angle (unit:
degrees)
² For other property settings please refer to the section “7.3 Graphic
universal properties”.
7.4.11 Pie
F The figure above is a selected pie; click the mouse on the pie
when under the not selected status to enter the selected status.
F Points 1-8 in the figure are the tensile points to adjust the graphic
size; 9 is the rotation point and 10 is the center.
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points.
F The figure above is an adjustable pie; double-click the mouse on
the pie when under the unadjustable status to enter the adjustable
status.
F Points 1 and 2 in the figure are adjustment points to adjust the
angle of the pie; when the mouse moves on top of a point, the
mouse cursor will change to“ ”.Press and hold the left mouse
button and drag the position of the adjustment point to adjust the
angle of the pie.
Pie properties
² Starting angle: Sets the starting angle of the pie angle (unit:
degrees).
² Scan angle: Sets the ending angle of the pie angle (unit: degrees).
² For other property settings please refer to the section “7.3 Graphic
universal properties”.
7.4.12 Pipe
F The figure above is a selected pipe; click the mouse on the tube
when under the not selected status to enter the selected status.
F Points 1-8 in the figure are the tensile points to adjust the graphic
size; 9 is the rotation point and 10 is the center.
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points.
F The figure above is an adjustable pipe; double-click the mouse on
the pie when under the unadjustable status to enter the adjustable
status.
F In the figure, 1 is the starting point, 2 is the inflection point to adjust
the shape of the pipe and 3 is the ending point; when the mouse is
moved on top of a point, the mouse cursor will change to“ ”.Press
and hold the left mouse button and move the position of the point to
adjust the shape of the pipe.
Pipe properties
² Whether to flow positively: Sets the direction which the liquid inside
the pipe flows; check it for positive flowing and uncheck for reverse
flowing.
² Liquid color: Sets the color of the liquid inside the pipe.
² Liquid width: Sets the sectional width of the liquid inside the pipe,
which is the liquid flow.
² Pipe color: Sets the color for the exterior of the pipe.
² Pipe width: Sets the diameter of the pipe.
² For other property settings please refer to the section “7.3 Graphic
universal properties".
7.4.13 Text
Graphic introduction:
F There are two points on 1 in the figure above: the tensile point and
the center; 2-8 are the tensile points to adjust the graphic size; 9 is
the rotation point.
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points.
Text properties
² Auto zoom: Sets whether the text content will zoom according to
the zooming size of the frame.
² Font: Sets the font format of the text; for example font style, size
and bold etc.
² For other property settings please refer to the section “7.3 Graphic
universal properties”.
7.5.1 Button
Ø Open the window interface and click on “Toolbox” → “Window
Controls” → “Button” in the tools window to the left; the toolbar is as
shown in the figure above.
Ø Move the mouse to the working area of the window, select a
starting point and press the left mouse button and drag the mouse
towards the bottom-right; after releasing the left mouse button, the
drawing of a button is complete, and a button will be generated.
Ø Just repeat the steps above if another button needs to be drawn.
Graphic introduction:
Graphic introduction:
F The figure above is a selected check box; click on the check box to
enter selected status.
F Points 1-8 in the figure are the tensile points to adjust the graphic
size; 9 is the rotation point and 10 is the center.
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points.
² Font: Sets the font format of the check box; for example font style,
size and bold etc.
² Text color: Sets the color of the text in the check box.
² For other property settings please refer to the section “7.3 Graphic
universal properties”.
7.5.3 ComboBox
Ø Open the window interface and click on “Toolbox” → “Window
Controls” → “ComboBox” in the tools window to the left; the toolbar
is as shown in the figure above.
Ø Move the mouse to the working area of the window, select a
starting point and press the left mouse button and drag the mouse
towards the bottom-right; after releasing the left mouse button, the
drawing of a combo box is complete, and a combo box will be
generated.
Ø Just repeat the steps above if another combo box needs to be
drawn.
Graphic introduction:
F The figure above is a combo box; click on the combo box to enter
selected status.
F Points 1-8 in the figure are the tensile points to adjust the graphic
size; 9 is the rotation point and 10 is the center.
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points.
Graphic introduction:
F Points 1-8 in the figure are the tensile points to adjust the graphic
size; 9 is the rotation point and 10 is the center.
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points.
Tag properties
² Font: Sets the font format of the text in the tag; for example font
style, size and bold etc.
² Line feed: Sets the line feed method of the text of the tag (overflow
line feed, no execution line feed, perform line feed).
² For other property settings please refer to the section “7.3 Graphic
universal properties”.
7.5.5 TextBox
Ø Open the window interface and click on “Toolbox” → “Window
Controls” → “TextBox” in the tools window to the left; the toolbar is
as shown in the figure above.
Ø Move the mouse to the working area of the window, select a
starting point and press the left mouse button and drag the mouse
towards the bottom-right; after releasing the left mouse button, the
drawing of a text box is complete, and a text box will be generated.
Ø Just repeat the steps above if another text box needs to be drawn.
Graphic introduction:
F The figure above is a selected text box; click on the text box to
enter selected status.
F Points 1-8 in the figure are the tensile points to adjust the graphic
size; 9 is the rotation point and 10 is the center.
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points.
Graphic introduction:
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points.
² Font: Sets the font format of the password box; for example font
style, size and bold etc.
² Border color: Sets the color of the border of the password box.
² For other property settings please refer to the section “7.3 Graphic
universal properties”.
7.5.7 DateTimePicker
Ø Open the window interface and click on “Toolbox” → “Window
Controls” → “DateTimePicker” in the tools window to the left; the
toolbar is as shown in the figure above.
Ø Move the mouse to the working area of the window, select a
starting point and press the left mouse button and drag the mouse
towards the bottom-right; after releasing the left mouse button, the
drawing of the date time picker is complete, and the date time picker
will be generated.
Ø Just repeat the steps above if another date time picker needs to
be drawn.
Graphic introduction:
F The figure above is a selected date time picker; click on the date
time picker to enter selected status.
F Points 1-8 in the figure are the tensile points to adjust the graphic
size; 9 is the rotation point and 10 is the center.
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points.
F 11 is the text block of the date ,12 is the date increase and
decrease button and 13 is the date selection button.
Date time picker properties
² Date: Text contents displayed in the date time picker.
² Maximum value: Set the maximum value of the selected range.
² Minimum value: Set the minimum value of the selected range.
² Date format: Sets the display format of the date time picker.
² Alignment: Sets the alignment method of the date time picker text
box.
² Time interval: Set the time interval of the date time picker.
² Upper and lower buttton: Set the availability of the date time.
² DisplayCurrentTime.
² Read-only: Sets whether the date time picker is read-only.
² Font: Sets the font format of the text in the date time picker; for
example font style, size and bold etc.
² Text color: Sets the color of the text in the date time picker.
² Enable: Sets the availability of the date time picker.
² Alignment: Sets the alignment method of the date time picker.
² For other property settings please refer to the section “7.3 Graphic
universal properties”.
7.5.8 DatePicker
Graphic introduction:
F The figure above is a selected date picker; click on the date picker
to enter selected status.
F Points 1-8 in the figure are the tensile points to adjust the graphic
size; 9 is the rotation point and 10 is the center.
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points.
F 11 is the text block of the date and 12 is the date selection button.
² Start date: Sets the start date of the date selection range.
² End date: Sets the end date of the date selection range.
² First day of the week: Sets which day of the week is the first day of
the week in the date.
² Date format: Sets date display format of the date: There are two
formats: Short and Long.
² Font: Sets the font format of the text displayed on the date; for
example font style, size and bold etc.
Graphic introduction:
F The figure above is a selected calendar; click on the calendar to
enter selected status.
Calendar properties
² Date selection: The selected year, month and day from the
calendar displayed on the calendar with a base color.
² Start date: Sets the start date of the calendar.
² End date: Sets the end date of the calendar.
² First day of the week: Sets which day of the week is the first day of
the week on the calendar.
² Font: Sets the font format of the text displayed on the calendar; for
example font style, size and bold etc.
² Border color: Sets the color of the calendar’s border.
² Enable: Sets the availability of the calendar.
² For other property settings please refer to the section “7.3 Graphic
universal properties”.
7.5.10 Image
Graphic introduction:
F Points 1-8 in the figure are the tensile points to adjust the graphic
size; 9 is the rotation point and 10 is the center.
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points.
Image properties
² For other property settings please refer to the section “7.3 Graphic
universal properties”.
7.5.11 GIFImage
Ø Open the window interface and click on “Toolbox” → “Window
Controls” → “GIFImage” in the tools window to the left; the toolbar is
as shown in the figure above.
Ø Move the mouse to the working area of the window, select a
starting point and press the left mouse button and drag the mouse
towards the bottom-right; after releasing the left mouse button, the
drawing of the gif image is complete, and the gif image will be
generated.
Ø Just repeat the steps above if another gif image needs to be
drawn.
Graphic introduction:
F The figure above is a selected image; click on the image to enter
selected status.
F Points 1-8 in the figure are the tensile points to adjust the graphic
size; 9 is the rotation point and 10 is the center.
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points.
Image properties
Graphic introduction:
The figure above is a selected nixie tube; click on the nixie tube to
enter selected status.The control point usage is the same with other
controls.
² Digit: Sets the digit displayed of the nixie tube integer part.
For other property settings please refer to the section “7.3 Graphic
universal properties”.
7.5.13 CurvedRuler
Graphic introduction:
F The figure above is a selected CurvedRuler; click on the
CurvedRuler to enter selected status.
F Points 1-8 in the figure are the tensile points to adjust the graphic
size; 9 is the rotation point and 10 is the center.
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points.
CurvedRuler properties
Ø StartAngle:Sets the starting angle of the CurvedRuler (unit:
degrees).
Ø ScanAngle:Sets the scaning angle of the CurvedRuler (unit:
degrees).
Ø StartValue:Sets the starting value of the CurvedRuler.
Ø EndValue:Sets the ending value of the CurvedRuler.
Ø BigTickNumber:Sets the big tick number of the CurvedRuler.
Ø SmallTickNumber:Sets the small tick number of the CurvedRuler.
Ø TickHeight:Sets the tick height of the CurvedRuler.
Ø TickPosition:Sets the tick position of the CurvedRuler.
Ø IsTextShow:Sets whether text is displayed of CurvedRuler.
Ø IsArcShow:Sets whether arc is displayed of CurvedRuler.
Ø LineBrush:Sets the current color of CurvedRuler.
Ø Font:Sets the font format of the text displayed on the CurvedRuler.
Ø TextMargin:Sets the distance between text and surrounding lines.
Ø For other property settings please refer to the section “7.3 Graphic
universal properties”.
7.5.14 Table
Graphic introduction:
Table properties
Ø FirstRowBackground: Sets background of the first row.
Ø FirstColumnBackground: Sets background of the first column(It
only works if the oblique line property is checked).
Ø DataBackground: Sets background of data area(It only works if the
row cross display property is unchecked).
Ø BorderStyle: Sets border style of the Table.
Ø GridStyle:Sets grid style of the Table.
Ø TableDesign: Sets the rows and columns of the Table.
Ø ObliqueLine: Sets whether to display the oblique line in the upper
left corner.
Ø RowCrossDisplay: Sets whether to enable row cross display.
Ø For other property settings please refer to the section “7.3 Graphic
universal properties”.
7.5.15 UniBarcode
Ø Open the window interface and click on “Toolbox” → “Window
Controls” → “UniBarcode” in the tools window to the left; the toolbar
is as shown in the figure above.
Ø Move the mouse to the working area of the window, select a
starting point and press the left mouse button and drag the mouse
towards the bottom-right. After releasing the left mouse button, the
drawing of the barcode is complete, and the barcode will be
generated.
Ø Just repeat the steps above if another UniBarcode needs to be
drawn.
Graphic introduction:
F The figure above is a selected UniBarcode; click on the
UniBarcode to enter selected status.
F Points 1-8 in the figure are the tensile points to adjust the graphic
size; 9 is the rotation point and 10 is the center.
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points.
UniBarcode properties
² Symbology: Sets the symbology of the UniBarcode.Currently
supports EAN, Code39, Codabar, Code128, etc.
² BarColor: Sets the bar color the UniBarcode .
² FillColor: Sets the fill color of the UniBarcode.
² Content: Sets the content of the UniBarcode.
² For other property settings please refer to the section “7.3 Graphic
universal properties”.
7.5.16 QRCode
Graphic introduction:
F The figure above is a selected QRCode; click on the QRCode to
enter selected status.
F Points 1-8 in the figure are the tensile points to adjust the graphic
size; 9 is the rotation point and 10 is the center.
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points.
QRCode properties
² ImagePath: Sets the image file path of the QRCode, support multi-
language function.
² BarColor: Sets the bar color of the QRCode.
² For other property settings please refer to the section “7.3 Graphic
universal properties”.
7.6.1 RealtimeChart
Graphic introduction:
F The figure above is a selected real-time curve; click on the real-time
curve to enter selected status.
F There are two points on 1 in the figure above: the tensile point and
the center; 2-8 are the tensile points and 9 is the rotation point,10 is
the center.
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points.
F It is the toolbar on the top of the figure, which is mainly used to
operate the chart.
Usage of the toolbar
RealtimeChart properties
Appearence
² Title: The text contents of the title , it can be left empty,Support for
multilingual functionality.
² TitleFont: Set the font for the title
² TitleColor: Set the color of the title font
² DisplayLegend: Whether display legend of a chart.
² MajorGrid: Set major grid.
² MinorGrid: Set minor grid
² Background: Set control background.
Series
² PositionLine: whether to display position line
² PositionLineColor: set the color of position line
² PositionLineFont: set the font type of position line
² TimeAxis&NumericalAxis:Set time axis or numerical axis of a
chart,take datetime axis as an example,as shown below:
The left part is the effect preview,the right part is the datetime axis
properties Please refer to the table below:
Property Description
Series Collection
The left part is add or delete members, each member is a
series(Series types include Line, Column, Scatter, SplineLine,
StepLine); the middle part can rank this series, the right part is the
selected series properties, as shown in the table below:
Property Description
Graphic introduction:
F The figure above is a selected history chart; click on the history
chart to enter selected status.
F There are two points on 1 in the figure above: the tensile point and
the center; 2-8 are the tensile points and 9 is the rotation point,10 is
the center.
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points.
F It is the statistics table on the bottom of the figure which is mainly
used to get the min , max, avg, sum and count of each curve.
F It is the toolbar on the top of figure which is used to operate chart.
² Status column display: Set whether to display the column in the
status column
² Set recent query time: Set the query time range: recent
one hour、recent one day、recent one week、recent one month、
recent three months、recent six months、recent one year、recent
three year、custom
² Last: set the scroll to the end time to see the chart
Property Description
² Datetime axis
Property Description
² For other property settings please refer to the section “7.3 Graphic
universal properties”.
7.6.3 XYChart
Ø Open the window interface and click on “Toolbox” → “Extended
controls” → “XYChart” in the tools window to the left; the toolbar is as
shown in the figure above.
Ø Move the mouse to the working area of the window, select a
starting point and press the left mouse button and drag the mouse
towards the bottom-right; after releasing the left mouse button, the
drawing of a XY chart is complete, and a XY chart will be generated.
Ø Just repeat the steps above if another XY chart needs to be drawn.
Graphic introduction:
F The figure above is a selected XY curve; click on the XY curve to
enter selected status.
F There are two points on 1 in the figure above: the tensile point and
the center; 2-8 are the tensile points and 9 is the rotation point,10 is
the center.
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points.
Usage of the tool bar
² Last: XY chart the last page data(When XY data is large, it will
be paged automatically)
² Forward: Page up
The left part is add or delete members,each member is a
series(Series type include Line, Column, SplineLine, Scatter,
PiecewiseLine, SwitchLine);the middle part can rank this series,the
right part is the selected series properties,as shown in the table
below:
Property Description
Property Description
² Y axis
Property Description
Graphic introduction:
F The figure above is a selected custom chart; click on the custom
chart to enter selected status.
F There are two points on 1 in the figure above: the tensile point and
the center; 2-8 are the tensile points and 9 is the rotation point,10 is
the center.
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points.
CustomChart properties
Appearance
² Title: The text contents of the title , it can be left empty,Support for
multilingual functionality.
² TitleFont: Set the font for the title
² TitleColor: Set the color of the title font
² DisplayLegend: Set whether to display the legend
² Background: Set the background of the chart
Series
² ChartType: Set the type of chart
² PositionLine: whether to display position line
² PositionLineColor: set the color of position line
² PositionLineFont: set the font type of position line
² AxisTranspose:Horizontal axis and vertical axis conversion
position(only affective after adding a curve in the chart)
² SeriesCollection: Configures the curve style and connected
variables in the figure; the configuration method is as follows:
Click the “ ” button and the custom curve editor window will appear;
add a curve, as shown in the figure below :
The left part is add or delete members,each member is a
series(Series type include Line, Scatter, Column, SplineLine,
StackColumn, StackColumn100);the middle part can rank this
series,the right part is the selected series properties,as shown in the
table below:
Property Description
Property Description
² Horizontal axis
Property Description
Graphic introduction:
F The figure above is a selected pie chart; click on the pie chart to
enter selected status.
F There are two points on 1 in the figure above: the tensile point and
the center; 2-8 are the tensile points and 9 is the rotation point,10 is
the center.
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points.
PieChart properties
Appearance
² Title: Set the title of the chart,Support for multilingual functionality.
² TitleFont: Set the title font of the chart
² TitleColor: Set the title color of the chart
² LabelFont: Set label font
² LabelColor: Set label color
² LabelPosition: Set label position
² DisplayLegend: Set whether to display the legend
² LegendFont: Set legend font
² LegendColor: Set legend color
² LegendPosition: Set legend position
² Background: Set control background.
Chart
² RefreshTime:Set the refresh time
² ColorMode:Set the color mode(Metro,Custom)
² Collection:Configures the components and connected variables of
the pie chart; it configures each component’s color and value etc.
The configuration method is as follows: Click the“ ”button and the
pie chart element editor window will appear; it has 4 elements
preset, as shown in the figure below:
The left part is add or delete members,each member is a series;
the middle part can rank this series,the right part is the selected
series properties,as shown in the table below:
Property Description
Data Format
² LabelContent:Set the label content(YValue,XValue,Pencentage)
² LabelFormat:Set the label
format(Integer,Double1,Double2,Scientific,Percent)
² DisplayData:Set whether to display data
² For other property settings please refer to the section “7.3 Graphic
universal properties”.
7.6.6 PieChart3D
Ø Open the window interface and click on “Toolbox” → “Extended
controls” → “PieChart3D” in the tools window to the left; the toolbar
is as shown in the figure above.
Ø Move the mouse to the working area of the window, select a
starting point and press the left mouse button and drag the mouse
towards the bottom-right; after releasing the left mouse button, the
drawing of a pie chart 3D is complete, and a pie chart 3D will be
generated.
Ø Just repeat the steps above if another XY chart needs to be
drawn.
Graphic introduction:
F The figure above is a selected pie chart 3D; click on the pie chart
3D to enter selected status.
F There are two points on 1 in the figure above: the tensile point and
the center; 2-8 are the tensile points and 9 is the rotation point,10 is
the center.
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points.
PieChart3D properties
Appearance
² Title: Set the title of the chart,Support for multilingual functionality.
² TitleFont: Set the title font of the chart
² TitleColor: Set the title color of the chart
² LabelFont: Set label font
² LabelColor: Set label color
² LabelPosition: Set label position
² DisplayLegend: Set whether to display the legend
² LegendFont: Set legend font
² LegendColor: Set legend color
² LegendPosition: Set legend position
² Background: Set control background.
Chart
² 3DTiltAngle: Set 3D pie chart tilt angle
² 3DHeight: Set 3D pie chart height
² 3DRotation: Set whether you can rotate the 3D pie chart
² 3DRotationAngle: Set 3D pie chart rotation angle
² RefreshTime: Set refresh time.Default value is one second
² Collection: Configures the components and connected variables of
the pie chart 3D; it configures each component’s color and value etc.
The configuration method is as follows:
Click the“ ”button and the pie chart 3D element editor window will
appear; it has 6 default elements, as shown in the figure below:
The left part is add or delete members, each member is a series; the
middle part can rank this series, the right part is the selected series
properties, as shown in the table below:
Property Description
Data Format
² DisplayData:Set whether to display data
² DisplayPoint:Set whether to display decimals in the data
² DisplayDataFormat:Set the data
format(XValue,YValue,Percentage,YofTot,XyPoint)
Toolbar
² Toolbar:Set Whether to display toolbar.
² ToolbarIcon:Set the toolbar icon type.
² For other property settings please refer to the section “7.3 Graphic
universal properties”.
7.6.7 ColumnChart
Ø Open the window interface and click on “Toolbox” →
“ExtendedControls” → “ColumnChart” in the tools window to the left;
the toolbar is as shown in the figure above.
Ø Move the mouse to the working area of the window, select a
starting point and press the left mouse button and drag the mouse
towards the bottom-right; after releasing the left mouse button, the
drawing of the column chart is complete, and the column chart will
be generated.
Ø Just repeat the steps above if another column chart needs to be
drawn.
Graphic introduction:
F The figure above is a selected column chart; click on the column
chart to enter selected status.
F There are two points on 1 in the figure above: the tensile point and
the center; 2-8 are the tensile points and 9 is the rotation point,10 is
the center.
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points.
ColumnChart properties:
Appearance
² Title: Set the title of the chart,Support for multilingual functionality.
² TitleFont: Set the title font
² TitleColor: Set the title color
² DisplayLegend: Set whether to display the legend
² LegendFont:Set the legend font
² LegendColor:Set the legend color
² LegendLocation:Set the legend location
² Background: Set control background.
Series
² RefreshTime: Set refresh time.Default value is one second
² AxisTranspose:Horizontal axis and vertical axis conversion
position(only affective after adding a curve in the chart)
² SeriesCollection: Configures the curve in the chart that is
associated with the variables to perform real-time display; the
Property Description
The left part is add or delete members,each member is a series;
the middle part can rank this series,the right part is the selected
series properties,as shown in the table below:
Property Description
Property Description
² Horizontal axis
Property Description
AxisCenter Set whether the axis is centered
AxisColor Set axis and text color
Set whether to transform the position
AxisPositionChange
of the axis
Font Set the text font style
Set the rotation angle of the
LabelRotationAngle
horizontal axis
ScrollBar Set whether to display the scollbar
Set the size ratio of scrollbar,the
ScrollBarSizeRatio
value range is 0.1~1
ShowGridline Set whether to display the grid line
Set the title of the axis,support for
Title
multilingual functionality.
Limit Line
² Thickness:Set the thickness of the limit line.
² LimitLineMaximum:Set the maximum value of the limit line.
² LimitLineMinimum:Set the minimum value of the limit line.
² UpperAndLowerDisplay:Set whether to display the limit line.
² UpperLimitLineColor:Set upper limit color.
² LowerLimitLineColor:Set lower limit color.
² For other property settings please refer to the section “7.3 Graphic
universal properties”.
7.6.8 HistoryColumnChart
Ø Open the window interface and click on “Toolbox” → “Extended
Controls” → “HistoryColumnChart” in the tools window to the left; the
toolbar is as shown in the figure above
Ø Move the mouse to the working area of the window, select a
starting point and press the left mouse button and drag the mouse
towards the bottom-right; after releasing the left mouse button, the
drawing of a history column chart is complete, and a history column
chart will be generated
Ø Just repeat the steps above if another history column chart needs
to be drawn.
Graphic introduction:
F The figure above is a selected history column chart; click on the
history column chart to enter selected status.
F There are two points on 1 in the figure above: the tensile point and
the center; 2-8 are the tensile points and 9 is the rotation point,10 is
the center.
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points
F It is the toolbar on the top of figure which is used to operate chart.
² Time setting: Set the start and end time of the query
Property Description
Property Description
Property Description
² CategoryAxis
Property Description
F The figure above is a selected record box; click on the record box
to enter selected status
F There are two points on 1 in the figure above: the tensile point and
the center; 2-8 are the tensile points and 9 is the rotation point,10 is
the center.
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points.
F It is the toolbar on the top of figure which is used to operate record
box.
² Set the status column format: set whether to display the specific
column in the status column
² Set recent query time: set the query time range: recent
one hour、recent one day、recent one week、recent one month、
recent three months、recent six months、recent one year、recent
three year、custom
Graphic introduction:
F The figure above is a selected alarm window; click on the alarm
window to enter selected status F There are two points on 1 in the
figure above: the tensile point and the center; 2-8 are the tensile
points and 9 is the rotation point,10 is the center.
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points.
² Set recent alarm query time: set the query time range:
recent one hour,recent one day,recent one week,recent one
month,recent three months,recent six months,recent one
year,recent three year,custom
² Set recent alarm query time: when "set recent alarm query
time" is "all alarm",user can set self-defined query range
² Set query filter condition: set query filter condition
² Toolbar:Set the alarm window toolbar wheather to show or not.
² ToolbarIcon:Set alarm box toolbar icon type.
Alarm Text Color
² DoubleLowAlarm:Set DoubleLow alarm text color.
² LowAlarm:Set LowAlarm text color.
² DoubleHighAlarm:Set DoubleHigh alarm text color.
² HighAlarm:Set HighAlarm text color.
² LowDeviationAlarm:Set LowDeviation alarm text color.
² UpperDeviationAlarm:Set UpperDeviation alarm text color.
² RateOfChangeAlarm:Set RateOfChange alarm text color.
² OnAlarm:Set OnAlarm text color.
² OffAlarm:Set OffAlarm text color.
² OnOrOffAlarm:Set OnOrOff alarm text color.
² ExpressionAlarm:Set Expression alarm text color.
Condition Filter
² HistoryAlarmFilter:Set history alarm filter condition.
² RealtimeAlarmFilter:Set real time alarm filter condition.
Click“ ” button,pup up the "Set Filter Condition" window,users can
choose according to their own needs:
² For other property settings please refer to the section “7.3 Graphic
universal properties”.
7.6.11 ScrollAlarm
Ø Open the window interface and click on “Toolbox” → “Extended
controls” → “ScrollAlarm” in the tools window to the left; the toolbar
is as shown in the figure above.
Ø Move the mouse to the working area of the window, select a
starting point and press the left mouse button and drag the mouse
towards the bottom-right; after releasing the left mouse button, the
drawing of a ScrollAlarm is complete, and a scroll alarm will be
generated.
Ø Just repeat the steps above if another scroll alarm needs to be
drawn.
Graphic introduction:
F The figure above is a selected scroll alarm; click on the scroll alarm
to enter selected status
F There are two points on 1 in the figure above: the tensile point and
the center; 2-8 are the tensile points and 9 is the rotation point,10 is
the center.
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points.
ScrollAlarm properties
Appearence
² RealTimeUpdate:Set whether to load real-time alarm automatically
at runtime.
² ScrollSpeed:Set the scroll speed of the scroll alarm content
² AlarmColor:Set the font color of the scroll alarm.
² FontSize:Set the font size of the scroll alarm.
² Background:Set the background of scroll alarm.
² For other property settings please refer to the section “7.3 Graphic
universal properties”.
7.6.13 RecipeBrowser
Graphic introduction
F The figure above is a selected recipe browser; click on the recipe
browser to enter selected status.
F There are two points on 1 in the figure above: the tensile point and
the center; 2-8 are the tensile points and 9 is the rotation point,10 is
the center.
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points.
Appearence
² Font:set recipe browser font
² FontColor:set recipe browser font color
² StatusBar:set StatusBar is show
² Background:set control background
² RecipeColumnWidth:set recipe column width(Auto,Star,Custom)
Toolbar
Graphic introduction
Ruler properties
Appearance
² Title: The text contents of the title , it can be left empty,Support for
multilingual functionality.
² TitleFont: Set the font for the title
² TitleColor: Set the color of the title font
² Background: Set control background.
Instrument
² PointerValue: set pointer value
² ValueUnit: set the value of the unit
² VariablePath: Set the VariablePath
² Pointer
Property Description
² Ruler
Property Description
² Bottomline
Property Description
Toolbar
² Toolbar:Set the alarm window toolbar wheather to show or not.
² ToolbarIcon:Set alarm box toolbar icon type.
Status Bar
² StatusBar:Set whether to display the status bar
² For other property settings please refer to the section “7.3 Graphic
universal properties”.
7.6.15 CircleGauge
Ø Open the window interface and click on “Toolbox” → “Extended
controls” → “CircleGauge” in the tools window to the left; the toolbar
is as shown in the figure above.
Ø Move the mouse to the working area of the window, select a
starting point and press the left mouse button and drag the mouse
towards the bottom-right; after releasing the left mouse button, the
drawing of a circle gauge is complete, and a circle gauge will be
generated.
Ø Just repeat the steps above if another circle gauge needs to be
drawn.
Graphic introduction
F The figure above is a selected circle gauge; click on the circle
gauge to enter selected status.
F There are two points on 1 in the figure above: the tensile point and
the center; 2-8 are the tensile points and 9 is the rotation point,10 is
the center.
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points.
CircleGauge properties
Appearance
² Title: The text contents of the title , it can be left empty,Support for
multilingual functionality.
² TitleFont: Set the font for the title
² TitleColor: Set the color of the title font
² Background: Set control background.
Instrument
² PointerValue: set pointer value
² ValueUnit: set the value of the unit
² VariablePath: Set the VariablePath
² Pointer
Property Description
² InstrumentPanel
Property Description
Toolbar
² Toolbar:Set the alarm window toolbar wheather to show or not.
² ToolbarIcon:Set alarm box toolbar icon type.
Status Bar
² StatusBar:Set whether to display the status bar
² For other property settings please refer to the section “7.3 Graphic
universal properties”.
7.6.16 VideoMonitor
Ø Open the window interface and click on “Toolbox” → “Extended
controls” → “VideoMonitor” in the tools window to the left; the toolbar
is as shown in the figure above.
Ø Move the mouse to the working area of the window, select a
starting point and press the left mouse button and drag the mouse
towards the bottom-right; after releasing the left mouse button, the
drawing of a Video Monitor is complete, and a Web browser will be
generated.
Ø Just repeat the steps above if another Video Monitor needs to be
drawn.
Graphic introduction
F The figure above is a selected Video Monitor; click on the Video
Monitor to enter selected status.
F There are two points on 1 in the figure above: the tensile point and
the center; 2-8 are the tensile points and 9 is the rotation point.
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points,10 is the center.
F It is the toolbar on the top of figure which is used to operate Video
Monitor.
Usage of menu
² Sign in: Sign in the user.
² Start Preview: Show video realtime.
² Capture Images: Capture frame one by one, save in folder set by
development.
² Start Recording: Record video and save in MP4 format.
² Playback: Play the saved video.
² Remote Setting: fetch or set video’s properties.
VideoMonitor properties
² AutomaticPreview: Get or set whether or not preview the video.
² PictureSavePath:get or set the save path of the picture captured.
² VideoPlaybackPath:get or set video playback path.
² DeviceConfiguration:Deivce IP, Devide port, and UserName,
password.
² For other property settings please refer to the section “7.3 Graphic
universal properties”
7.6.17 WebBrowser
Ø Open the window interface and click on “Toolbox” → “Extended
controls” → “WebBrowser” in the tools window to the left; the toolbar
is as shown in the figure above.
Ø Move the mouse to the working area of the window, select a
starting point and press the left mouse button and drag the mouse
towards the bottom-right; after releasing the left mouse button, the
drawing of a Web browser is complete, and a Web browser will be
generated.
Ø Just repeat the steps above if another Web browser needs to be
drawn.
Graphic introduction
F The figure above is a selected Web browser; click on the Web
browser to enter selected status.
F There are two points on 1 in the figure above: the tensile point and
the center; 2-8 are the tensile points and 9 is the rotation point.
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points,10 is the center.
F It is the toolbar on the top of figure which is used to operate web
browser.
F It is the status bar on the bottom of figure which is used to display
the current progress.
Graphic introduction
F The figure above is a selected RTSP Video Monitor; click on the
RTSP Video Monitor to enter selected status.
F There are two points on 1 in the figure above: the tensile point and
the center; 2-8 are the tensile points and 9 is the rotation point.
F Above point 2 and below point 6 in the figure are the horizontal
distortion points. The right of point 4 and the left of point 8 are the
vertical distortion points,10 is the center.
F The RTSP Video Monitor don't support rotation and distortion.
F The lower part of the figure is the toolbar, which is used to perform
various operations on the RTSP Video Monitor.
Usage of menu
² Select Video: used to select the video source displayed in the
screen.
² Start : Display the picture of the video source.
² Start Recording: Record video and save in webm format.
² Playback: Search by creation time and select one from the list to
play.
² Refersh: when the video playback is abnormal,click refresh to reset
the video playback.
RTSPVideoMonitor properties
² VideoSet: Edit video source.
The category name added here can be edited and renamed;
Select a category and perform operations such as “Rename” and
“Delete” by right-clicking the mouse.
Name: The system will choose a name(New Category) by default
and the user can also change it. The name of the graphic category
cannot be repeated as other created graphic category.
7.7.3 Expanding the gallery
The models in the gallery are the grouped graphics in the sketchpad;
models can be drawn by the following three steps:
1. Draw the sub-graphics that forms the model.
2. Adjust the size, position and stacking levels of the sub-graphics
and then group them into a graphic.
3. Add the new grouped graphic into the gallery.
In order to achieve “all-mouse” operations, the DIAView software
has the convenient right-click menu (please refer to “4.5 DIAView
Right-click menu introduction” for the specific functions), as shown in
the figure below:
7.8.2 Rotation
When the graphic drawn needs to be rotated, place the mouse on
the “rotation point” and the mouse cursor will change to ,now you
can press and hold the left mouse button and drag the rotation point
to rotate the graphic.
Graphic rotation uses the center point as the center for rotating. It
can be rotated using the default center point location (the center of
the graphic), or the center point can also be changed and then
rotated, as shown in the figure below:
Framed graphics:
Aligned effect:
Ø Align Right
Use the reference graphic as the basis and make the right edge
of the other selected graphics align with the right edge of the
reference graphic;
The shortcut button in the “Start” menu is
Ø Align Top
Use the reference graphic as the basis and make the top edge of
the other selected graphics align with the top edge of the
reference graphic;
The shortcut button in the “Start” menu is
Ø Align Bottom
Use the reference graphic as the basis and make the bottom
edge of the other selected graphics align with the bottom edge of
the reference graphic;
The shortcut button in the “Start” menu is
Ø Align Center
Use the reference graphic as the basis and make the X-axis of
geometric center of the other selected graphics the same as the
X-axis of the geometric center of the reference graphic;
The shortcut button in the “Start” menu is
Ø Align Middle
Use the reference graphic as the basis and make the Y-axis of
geometric center of the other selected graphics the same as the
Y-axis of the geometric center of the reference graphic;
The shortcut button in the “Start” menu is
Ø Same center
Use the reference graphic as the basis and make the X and Y-
axis of geometric center of the other selected graphics the same
as the X and Y-axis of the geometric center of the reference
graphic;
The shortcut button in the “Start” menu is
Ø Distribute Vertical
Distribute the geometric center of three or more selected graphic
objects in the sketchpad evenly in the vertical direction,The
shortcut button in the “Start” menu is: ; as shown in the figure
below:
Ø Distribute Horizontal
Distribute the geometric center of three or more selected graphic
objects in the sketchpad evenly in the horizontal direction.
The shortcut button in the “Start” menu is: ; as shown in the figure
below:
7.8.5 Layer
Layer refers to the display order of graphics in the sketchpad; the
graphic first drawn in the sketchpad of the DIAView is at the inner
layer (bottom layer) and the graphics later drawn is at the outer layer
(top layer).
An example is as follows:
Ø Place at bottom layer
Ø Move up a layer
1. When multiple graphics are framed with the mouse, the graphic
that is first drawn in the sketchpad is the reference graphic;
Ø Same Width Use the reference graphic as the basis and make the
width of the other selected graphics the same as the width of the
reference graphic.
The shortcut button in the “Start” menu is ;as shown in the
figure below:
Ø Same Height
Use the reference graphic as the basis and make the height of
the other selected graphics the same as the height of the
reference graphic.
The shortcut button in the “Start” menu is .
Ø Same Size
Use the reference graphic as the basis and make the size of the
other selected graphics the same as the size of the reference
graphic.
The shortcut button in the “Start” menu is 。
7.8.7 Grouping
Grouping refers to forming two or more graphics into a whole,
forming a new graphic making it easier for user to use. For example:
we can group graphics such as fans, motors and water tanks and
place it in the graphic library, so we can easily access them from the
image library when we need to use it again.
Ø Grouping
Ø Ungroup
Select the grouped graphic and then click the “Ungroup” shortcut
button in the “Start” menu, and the various sub-graphics in the
group will exist independently in the sketchpad.
7.8.8 Distortion
1、Distortion: Making the graphic tilt; distorting is divided into
horizontal distortion and vertical distortion.
c、Distorted graphic:
2、Vertical offset: Draw two rectangles with identical sizes, set the
vertical offset property value of the bottom rectangle to 50.
after shifting
7.9 Group graphic extended properties
Click“ ” to add property for grouping graphic in the extended
property window and configure the added extended property in the
pop-up window.
2.Script correlation: Click button
to write script in the pop up window,the script will be triggered during
development. In the script, "value" can be used instead of the value
of the extension attribute being configured, for example:
Rectangle0.width = value; You can also set the attribute value
directly, for example: Rectangle0.width = 200.
7.10.1 Find
In the development environment, open the project and press Ctrl + F
to open the “find and replace” window. The find window is displayed
by default, as shown in the following figure:
Find Content: Enter the content to search in this edit box.The find
types include string, variable, control and security, as shown in the
following figure:
When the search type is "variable" and "safe area", click the button
to select the search content quickly.as shown in the following figure:
Find Condition:
² Match whole word: Select this item and only examples that
matches all words in the “Find target” string will be displayed. For
example, find “aaa” and the result will return “aaa” instead of
“baaa” or “aaac”.
² Match case: If this item is selected, it will only display examples
that have exactly the same cases as the string content in “Find
content”.
² Find Range:Contains two options--“project” and “window ”.When
the “project ” is selected, it means to find content in the whole
project; when the “window” is selected, it means to find content
only in all windows.
² Find Type:Contains four types-
-“string”,“variable”,“control”,“security”.
Shortcut menu:
Right click any node in the result tree to call out the position function,
as shown in the following figure:
Click "position" to jump to the corresponding position (only can jump
to window currently ), as shown in the figure above.Click "position"
button then open "window0", and select "text0" automatically.
7.10.2 Replace
In the development environment, open the project and press Ctrl + F
to open the “find and replace” window. Click the label "Replace"to
open replace window, as shown in the following figure:
Find Content: Enter the content to search in this edit box.
Replace Content: Enter the replacement content in this edit box,
select the node to be replaced in the search result tree, and then click
"Replace" to batch replace the specified items. For example, as
shown in the following figure:
Find Condition:
Refer to section "7.10.1 Find".
Shortcut menu:
Refer to section "7.10.1 Find".
8.1 Overview
Animation refers to the correspondence between the created
window element and the internal variables; it makes the properties of
the window element change dynamically according to the field
acquired data, and truly displays the dynamic scene of the industrial
field. For example, simulation of fluid flow in the pipeline in the
window, real-time changes of instrument data, rotation of electrical
machineries and the flashing of alarm etc.
Ø “Delete” button: Pressing this button after selecting a certain
configuration item will delete that configuration item.
Step 3: When configuration is complete, press the “OK” button to
complete the configuration of the “DiscreteRotation” animation; the
animation configuration of this graphics will be displayed in the
“Animation” window, as shown in the figure below:
To delete the animation, simply select the animation in the animation
list and then right-click the mouse and select “Delete”.
8.3 Appearance animation
Appearance animation refers to changing the brush color of the
graphic, and also changing the properties of the graphic including
the “background color/fill color” and “line color/border color”.
Filling configuration:
l =: Equal to (preset)
l !=: Not equal to
To delete the animation, simply select the animation in the animation
list and then right-click the mouse and select “Delete”.
※ What’s different when configuring “VerticalFill” animations:
Fill Attributes:
Ø VerticalDiscreteFill: Sets the fill direction; it is a drop-down menu
that includes 3 options:
l Top to Bottom
l Bottom to Up
l Center to Sides
2. Steps to configure “HorizontalDiscreteFill” animation are as
follows:
Step 1: Open the project window where the animation needs to be
configured under the DIAView software development environment →
select the graphic object to configure animation in the sketchpad →
open the “Animation” window → select “Fill”→ click the button in the
“HorizontalDiscreteFill” field, as shown in the figure below:
Step 2: The horizontal discrete fill animation configuration window
will appear, as shown in the figure below:
The meanings of each setting in the configuration window are as
follows:
Expression: Enter the variable name or expression; you can also
click the button to open the variable browser to select a
variable; the “Clear” button can clear the contents in the input box.
Filling configuration:
Ø Comparison Operators: Sets the comparison operator symbol
between the “Expression” and “Value”, it is a drop-down menu that
includes 6 options:
l <: Less than
l <=: Less than or equal to
l =: Equal to (preset)
l !=: Not equal to
l >=: Greater than or equal to
l >: Greater than
Ø Value: Sets the reference value for the “Expression” to compare to;
it can be an integer or decimal .
Ø Percentage: Sets the corresponding fill percentage.
Ø “Add” button: Press this button to add configuration items, as
shown in the figure below:
Ø “Delete” button: Pressing this button after selecting a certain
configuration item will delete that configuration item.
Fill Attributes:
Ø HorizontalFillDirection: Sets the fill direction; it is a drop-down
menu that includes 3 options:
l Left to Right
l Right to Left
l Center to Sides
Step 3:When configuration is complete, press the “OK” button to
complete the configuration of the “HorizontalDiscreteFill” animation;
the animation configuration of this graphics will be displayed in the
“Animation” window, as shown in the figure below:
Ø “Delete” button: Pressing this button after selecting a certain
configuration item will delete that configuration item.
Zoom Attributes:
Ø HorizontalZoomDirection: Sets the zoom direction; it is a drop-
down menu that includes 3 options
l Left to Right
l Right to Left
l Center to Sides
Step 3: 3:When configuration is complete, press the “OK” button to
complete the configuration of the “Horizontal discrete zoom”
animation; the animation configuration of this graphics will be
displayed in the “Animation” window, as shown in the figure below:
To delete the animation, simply select the animation in the animation
list and then right-click the mouse and select “Delete”.
※ What’s different when configuring “Vertical discrete zoom”
animations:
Zoom Attributes
Ø VerticalZoomDirection: Sets the zoom direction; it is a drop-down
menu that includes 3 options
l Top to Bottom
l Bottom to Up
l Center to Sides
8.6 Move animation
Move animation refers to controlling the position of the graphic
object through variables or expression values and changing the
“coordinates” property of the graphic object.
Move animation is divided into three types: “HorizontalMove”,
“VerticalMove” and “DiscreteMove”, in which the configuration steps
of horizontal and vertical movement are the same. The following are
the configuration steps:
1.Steps to configure “HorizontalMove” animations are as follows:
Step 1:Open the project window where the animation needs to be
configured under the DIAView software development environment →
select the graphic object to configure animation in the sketchpad →
open the “Animation” window → select “HorizontalMove”→ click the
button in the “HorizontalMove” bar, as shown in the figure below:
Step 2: The horizontal move animation configuration window will
appear, as shown in the figure below:
The meanings of each setting in the configuration window are as
follows:
Expression: Enter the variable name or expression; you can also
click the button to open the variable browser to select a
variable, the “Clear” button can clear the contents in the input box.
Left:
Ø Value: Sets the minimum value of the “Expression”
Ø Location: Sets the coordinates of the left-most position that can be
reached for horizontal movement
Right:
Ø Value: Sets the maximum value of the “Expression”
Ø Location: Sets the coordinates of the right-most position that can be
reached for horizontal movement
Step 3:When configuration is complete, press the “OK” button to
complete the configuration of the “HorizontalMove” animation; the
animation configuration of this graphics will be displayed in the
“Animation” window, as shown in the figure below:
To delete the animation, simply select the animation in the animation
list and then right-click the mouse and select “Delete”.
2. Steps to configure “DiscreteMove” animations are as follows:
Step 1:Open the project window where the animation needs to be
configured under the DIAView software development environment →
select the graphic object to configure animation in the sketchpad →
open the “Animation” window → select “DiscreteMove”→ click the
button in the “DiscreteMove” field, as shown in the figure below:
Step 2: The discrete move animation configuration window will
appear, as shown in the figure below:
The meanings of each setting in the configuration window are as
follows:
Expression: Enter the variable name or expression; you can also
click the button to open the variable browser to select a
variable; the “Clear” button can clear the contents in the input box.
Move configurations:
Ø Comparison Operators: Sets the comparison operator symbol
between the “Expression” and “Value”, it is a drop-down menu that
includes 6 options:
l <: Less than
l <=: Less than or equal to
l =: Equal to (preset)
l !=: Not equal to
l >=: Greater than or equal to
l >: Greater than
Ø Value: Sets the reference value for the “Expression” to compare to;
it can be an integer or decimal.
Ø Coordinate: Sets the correspondingposition coordinates.
Ø “Add” button: Press this button to add configuration items, as
shown in the figure below:
Ø “Delete” button: Pressing this button after selecting a certain
configuration item will delete that configuration item.
Step 3:When configuration is complete, press the “OK” button to
complete the configuration of the “DiscreteMove” animation; the
animation configuration of this graphics will be displayed in the
“Animation” window, as shown in the figure below:
To delete the animation, simply select the animation in the
animation list and then right-click the mouse and select “Delete”.
8.7 Visibility animation
Visibility animation refers to controlling the visibility of the graphic
object through variables or expression values and changing the
“Visibility” property of the graphic object.
According to the visibility effect, visibility animations are divided
into two types: “Visibility” and “Blink”; the difference between them
are: Blinking makes the graphic switch between display and hide
according to a fixed frequency in order to achieve blinking effects;
visibility changes the graphic from display to hide or from hide to
display according to the conditions; it is only a single action.
1. Steps to configure blinking animation are as follows:
Step 1:Open the project window where the animation needs to be
configured under the DIAView software development environment →
select the graphic object to configure animation in the sketchpad →
open the “Animation” window → select “Blink” → click the button in
the “Blink” bar, as shown in the figure below:
Step 2: The blink animation configuration window will appear, as
shown in the figure below:
The meanings of each setting in the configuration window are as
follows:
Expression: Enter the variable name or expression; you can also
click the button to open the variable browser to select a
variable, the “Clear” button can clear the contents in the input box.
BlinkSpeed: Sets the Blink frequency; it is a drop-down menu with
3 options:
l Slow
l Medium
l Fast
Step 3: When configuration is complete, press the “OK” button to
complete the configuration of the “Blink” animation; the animation
configuration of this graphics will be displayed in the “Animation”
window, as shown in the figure below:
To delete the animation, simply select the animation in the animation
list and then right-click the mouse and select “Delete”.
2. Steps to configure visibility animation are as follows:
Step 1:Open the project window where the animation needs to be
configured under the DIAView software development environment →
select the graphic object to configure animation in the sketchpad →
open the “Animation” window → select “Visibility”→ click the button
in the “Visibility” bar, as shown in the figure below:
Step 2: The visibility animation configuration window will appear, as
shown in the figure below:
The meanings of each setting in the configuration window are as
follows:
Expression: Enter the variable name or expression; you can also
click the button to open the variable browser to select a
variable; the “Clear” button can clear the contents in the input box.
Step 3: When configuration is complete, press the “OK” button to
complete the configuration of the “Visibility” animation; the animation
configuration of this graphics will be displayed in the “Animation”
window, as shown in the figure below
Ø “Delete” button: Pressing this button after selecting a certain
configuration item will delete that configuration item.
Step 3:When configuration is complete, press the “OK” button to
complete the configuration of the “LineFlow” animation. The
animation configuration of this graphics will be displayed in the
“Animation” window, as shown in the figure below:
To delete the animation, simply select the animation in the animation
list and then right-click the mouse and select “Delete”.
2. Steps to configure flow control animation are as follows:
Step 1:Open the project window where the animation needs to be
configured under the DIAView software development environment →
select the graphic object to configure animation in the sketchpad →
open the “Animation” window → select “FlowControl”→ click the
button in the “FlowControl” bar, as shown in the figure below:
The meanings of each setting in the configuration window are as
follows:
Expression: Input the associated variable name or string value;
you can also click the button to open the variable browser to
select a variable; the “Clear” button can clear the contents in the
input box.
Step 3:When configuration is complete, press the “OK” button to
complete the configuration of the “TextDisplay” animation. The
animation configuration of this graphics will be displayed in the
“Animation” window, as shown in the figure below:
l Text display animation can not only display single variable value but
also can recycle displaying all the alarm information of associated
alarm group.
l To delete the animation, simply select the animation in the
animation list and then right-click the mouse and select “Delete”.
8.10 Skew animation
Skew animation refers to controlling the slope level of the graphic
object through variables or expression values and changing the
“Skew” property of the graphic object.
Slope animation is divided into four types: “HorizontalSkew”,
“VerticalSkew” ,“HorizontalDiscreteSkew” and
“VerticalDiscreteSkew”.
“HorizontalSkew” animation refers to the slope level of the graphic
object in the horizontal direction.
“VerticalSkew” animation refers to the slope level of the graphic
object in the vertical direction.
“HorizontalDiscreteSkew” means that the horizontal slope angle of
the graphic object is related to the discrete variable.
“VerticalDiscreteSkew” means that the vertical slope angle of the
graphic object is related to the discrete variable.
1. The configuration process is as follows,take the animation of
"horizontal Skew" and "horizontal discrete Skew" as examples:
Step 1:Open the project window where the animation needs to be
configured under the DIAView software development environment →
select the graphic object to configure animation in the sketchpad →
open the “Animation” window → select “HorizontalSkew”→ click the
button in the “HorizontalSkew” bar, as shown in the figure below:
Step 2: The horizontal skew animation configuration window will
appear, as shown in the figure below:
The meanings of each setting in the configuration window are as
follows:
Expression: Input the variable name or expression; you can also
click the button to open the variable browser to select a
variable; the “Clear” button can clear the contents in the input box.
MinimumValue:
Ø Value: Sets the minimum value of the “Expression”
Ø HorizontalSkew: Sets the minimum value for the Horizontal slope
MaximumValue:
Ø Value: Sets the maximum value of the “Expression”
Ø HorizontalSkew: Sets the maximum value for the Horizontal slope
Step 3: When configuration is complete, press the “OK” button to
complete the configuration of the “HorizontalSkew” animation; the
animation configuration of this graphics will be displayed in the
“Animation” window, as shown in the figure below:
To delete the animation, simply select the animation in the animation
list and then right-click the mouse and select “Delete”.
Step 1:
l =: Equal to (preset)
Ø Value: Sets the reference value for the “Expression” to compare to;
it can be an integer or decimal.
Ø Button functions:
l “>” : Add a window to selected window
l “>>”: Add all windows to the selected window
l “↓” : Move the window down
l “↓↓”: Move the window to the bottom
l “↑↑”: Move the window to the top
l “↑” : Move the window up
l “<” : Remove a window from selected window
l “<<”: Remove all windows from selected window
To delete an event, simply select the event in the event list and
then right-click the mouse and select “Delete”.
9.7 Value input event
Value Input event is when clicking a graphic object in the window
triggers the value input window of the DIAView software for value
input operations.
There are four types of value input events: AnalogValueInput,
DiscreteValueInput, StringInput and ButtonInput.
1.AnalogValueInput:
When this event is set for a graphic object, a analog value input
dialog will appear when this graphic object is clicked by the mouse in
the DIAView software runtime environment, including digital buttons;
users can click the digital buttons to input numbers to change the
value of the associated analog variable. Configuring steps are as
follows:
Step 1: Open the project window where the event needs to be
configured under the DIAView software development environment →
select graphic object to configure event in the sketchpad → open
“Event” window → select “AnalogValueInput”→ click the button in
“AnalogValueInput” bar, as shown in the figure below:
Step 2: The Analog Value Input configuration window will appear, as
shown in the figure below:
The meanings of each setting in the configuration window are as
follows:
Ø Variable:
l The associated variable name, the variable type is analog value;
you can also click the button to open the variable browser to
select a variable. The “Clear” button can clear the contents in the
input box
Ø Value range:
l MinimumValue: Sets the minimum value that can be input
l MaximumValue: Sets the maximum value that can be input
Ø Input Panel Size:
l Set the size of pop-up analog input keyboard
Ø Auto create animation:
l Set whether to automatically create the corresponding value
display animation(text, textbox, and label support this function)
Step 3:When configuration is complete, press the “OK” button to
complete the configuration of the “AnalogValueInput” event. The
event configuration of this graphic will be displayed in the “Event”
window, as shown in the figure below:
To delete an event, simply select the and then right-click the
mouse and select “Delete”.
2.DiscreteValueInput:
When this event is set for a graphic object, a discrete value input
dialog will appear when this graphic object is clicked by the mouse in
the DIAView software runtime environment.Users can set the
button’s text according to associated discrete variable value is True
or False. Configuring steps are as follows:
Step 1: Open the project window where the event needs to be
configured under the DIAView software development environment →
select the graphic object to configure event in the sketchpad → click
the “Value Input ” in the “Event” window → select
“DiscreteValueInput” from the options→ click the button in the
“DiscreteValueInput”bar, as shown in the figure below:
Step 2: The Discrete Value Input configuration window will appear,
as shown in the figure below:
The meanings of each setting in the configuration window are as
follows:
Ø Variable:Variable:
l The associated variable name, the variable type is digital value; you
can also click the button to open the variable browser to select
a variable; the “Clear” button can clear the contents in the input box
Ø Button text:
l SetTrue: Text content displayed by the button when the value is
True
l SetFalse: Text content displayed by the button when the value is
False
Ø Auto create animation:
l Set whether to automatically create the corresponding value
display animation(text, textbox, and label support this function)
Step 3:When configuration is complete, press the “OK” button to
complete the configuration of the “DiscreteValueInput” event. The
event configuration of this graphic will be displayed in the “Event”
window, as shown in the figure below:
To delete an event, simply select the event and then right-click
the mouse and select “Delete”.
3.StringInput:
When this event is set for a graphic object, a string input dialog will
appear when this graphic object is clicked by the mouse in the
DIAView software runtime environment; it includes letters and
number input keyboard and users can click the keys to enter strings
to change the value of the associated string variable.
Step 1:Open the project window where the event needs to be
configured under the DIAView software development environment →
select the graphic object to configure event in the sketchpad → click
the “Value Input” in the “Event” window → select “StringInput” from
the options→ click the button in the “StringInput” bar, as shown in the
figure below:
Step 2: The String Input configuration window will appear, as shown
in the figure below:
The meanings of each setting in the configuration window are as
follows:
Ø Variable:
l The associated variable name, the variable type is text amount; you
can also click the button to open the variable browser to select
a variable. The “Clear” button can clear the contents in the input box
Ø Display password:
l If this checkbox is selected, the input value will be displayed in a
password form
Ø Keyboard size:
l Set the size of pop-up string input keyboard under the runtime
environment
Ø Auto create animation:
l Set whether to automatically create the corresponding value
display animation(text, textbox, and label support this function)
Step 3:When configuration is complete, press the “OK” button to
complete the configuration of the “StringInput” event. The event
configuration of this graphic will be displayed in the “Event” window,
as shown in the figure below:
To delete an event, simply select the event and then right-click
the mouse and select “Delete”.
4.ButtonInput:
When this event is set for a graphic object, if this graphic object is
clicked with the mouse under the DIAView software runtime
environment, the value of the associated variable will change
according to the setting method ; for example, reset the value ,
addition or subtraction between the variable value and the setting
value etc. Configuring steps are as follows:
Step 1:Open the project window where the event needs to be
configured under the DIAView software development environment →
select the graphic object to configure event in the sketchpad → click
the “Value Input ” in the “Event” window → select “ButtonInput” from
the options→ click the button in the “ButtonInput” bar , as shown in
the figure below:
Step 2: The Button Input configuration window will appear, as shown
in the figure below:
To delete an event, simply select the event in the event list and
then right-click the mouse and select “Delete”.
9.9 Control event
Control event is an unique event to a form control. Different controls
have different events.
For example, the text box has a "TextChanged" event, and the
check box has "checked" and "unchecked" events. All events can be
implemented through editing script.
The followingt through the "TextChanged" event of the text box as
an example to illustrate the configuration process of the event.
The configuration process is as follows:
Step 1:Open the project window where the animation needs to be
configured under the DIAView software development environment →
select graphic object to configure event in the sketchpad → open
“Event” window → select “Control”→ click the button in
“TextChanged” bar, as shown in the figure below:
Step 2: The Script Editor window will appear, as shown in the figure
below:
Step 3: Write the script (The DIAView software uses the Visual Basic
Script; the script editor will check for basic syntax errors), as shown in
the figure below:
Step 4: Once the script is written and checked with no errors, click
“Save and exit button” to complete event configuration; information
on the configured event will be displayed in the event window, as
shown in the figure below:
To delete an event, simply select the event in the event list and
then right-click the mouse and select "Delete".
The Configuration process of other controls is the same as
above.
Ø Control events include:
l CheckedBox: Checked event、Unchecked event
l ComboBox: SelectionChanged event
l TextBox: TextChanged event
l PasswordBox: PasswordChanged event
l DateTimePicker: ValueChanged event
l DatePicker: SelectedDateChanged event
l Calendar: SelectedDateChanged event
l RecipeBrowser: SelectionChanged event
l AlarmWindow: SelectionChanged event
9.10 Window program event
Window program event is to set the custom time interval program
executed in the runtime environment.
Window program event has only one type: Window Program.
Configuration steps are as follows:
Step 1: 1:Open the project window where the event needs to be
configured under the DIAView software development environment →
select window to configure event in the sketchpad → open “Event”
window → select “Window Program ”→ click the button in “Window
Program” bar , as shown in the figure below:
Step 2: The Window Program configuration window will appear, click
"Add" button ,as shown in the figure below:
The meanings of each setting in the configuration window are as
follows:
Step 4: Click the button below “Program”,pop up the script editor
window ,Script can be written in it ,as shown in the figure below:
Step 5: Once the script is written and checked with no errors, click
“Save and exit button” to complete event configuration; information
on the configured event will be displayed in the Program, as shown in
the figure below:
Step 6: Click “OK” button after the configuration is done, information
on the configured event will be displayed in the event window, as
shown in the figure below:
9.11 Shortcut program event
The shortcut key program event is the operation of pressing the
keyboard combination to execute a custom script.
There are two types of shortcut key program events: window
shortcut key events and global shortcut key events.
Step 2: The window shortcut program configuration window will
appear, click "Add" button ,as shown in the figure below:
The items in the window are as follows:
Name:Shortcut key name, cannot be empty, and cannot be repeated
with others, the maximum can only be 50 characters
Shortcut key:Keyboard key combination, not repeatable
Program:Shortcut key script content.When checkbox in the same
row is selected, the program content cannot be empty.Click the "..."
button in the column to open the script editor.
For the usage of the script editor, please refer to the chapter: "20.
Script".
IsEnabled:Set whether to enable, the shortcut key can trigger the
script execution when selected
Description:Content description, the maximum input is 200
characters
Add:Add a new record
Delete:Delete the selected record
Clear:Clear all records in the list. Before clearing, a confirmation
dialog box will pop up. After agreeing, the list content will be cleared.
OK:Save and close the editing window
Cancel:Close the editing window
Step 2: The global shortcut program configuration window will
appear, click "Add" button ,as shown in the figure below:
For the meaning of each setting in the window, please refer to
"Window Shortcut Program".
3. Additional information
During HMI operation, when multiple windows with the same
shortcut keys are opened at the same time, pressing the shortcut
key will execute the shortcut key program matched in each window.
The priority of the global shortcut key program is higher than that of
the window shortcut key program, that is, when the window shortcut
key conflicts with the global shortcut key, only the global shortcut key
program is executed.
10. Report overview
Report tool that offerintg "Semblable excel" operation is used to
make common production report(daily report,monthly report, yearly
report),which is also used to make various complicated format report
flexibly to achive querying,displaying,printing and output to
realtime,history and statistic data.
Report can not only display the data of realtime and history database
but also can query and access to the typical database like Mysql,
SQL Server, Oracel, Access etc.
10.1 Report template design
Ø Open the project window under the DIAView software development
environment → open the “Report” node in the project index tree →
click the "New Report"option in the right-click menu, as shown in the
figure below
Ø Just repeat the steps above if another recipe browser needs to be
drawn.
F The figure above is report template menu which can be used to
design for report
Usage of the toolbar
² Import: Import report templates or excel tables
² Export As: Expor as Excel, PDF, CSV file
² Print: Set report template printing parameter and print
Preview:
Preview: preview current report
Save template: save current template
Up Page: Preview previous page
Down Page:Preview next page
Printing Range Page: Printing selected range page
Print Current Page: Print current page
Print All: Print all the page
Page:
Orientation: Landscape or portrait
Scaling: print accrording to ratio
1 page width 1 page height : adjust table to one page
1 page width 0 page height : adjust all column to one page
0 page width 1 page height : adjust all row to one page
0 page width 0 page height : no zoom
Margin : Set print margins
Row Column Headers : Set whether to display the row number and
column headers.
Show Gridline:Set whether to display gridline.
Page Setting:
PageNum: Insert page number in header and footer
PageCount: Insert page count in header and footer
Date: Insert date in header and footer
Time: Insert time in header and footer
UserName : Insert user name in header and footer
Header : Set the content of the header
Footer : Set the content of the footer
First page is different : Set whether the header and footer of the first
page are different from other pages
² Font setting: set font style, size, bold,slope,underline,cell border
style, cell fill color, font color and font alignment
² Word wrap: set wtether to word wrap if the content is more the
length of cell
² Merge and center: merge the selected cell or cancel merging
² Insert Sheet: insert sheet
² Insert Image: insert image
² Insert SubReport: insert a subreport in the specified area of the
current worksheet
² Delete Sheet: delete sheet
² Delete SubReport: delete the subreport
² Row Count: set row count
² Row Height: set row height
² Column Count: set column count
² Column Width: set column width
² Freeze Panes: freeze the selected row and column
² Freeze First Column: freeze first column
² Freeze Top Row: freeze the first row
² Cancel Freeze: cancel freeze
² Protect Sheet: set whether to project sheet
² Realtime Variable: design realtime variable report template,the
configuration is as follows:
² PDF Setting
PDF Region
Ø Open or add a report template.
Ø Open “Report guide” by click report guide
Description:
(1)Chart type,include Class Day Week Month Quarter and Year.
(2)Value type, include Spurt Average Max Min and Basic.
(3)DateTime,use to set query’s starttime ,time duration.
(4)LeftTop,It is sheet’s left and top location.
(5)Row/Column statistics,include Average,Sum,Max and Min.
Description:
(1)Search,It is used to find and mark history group variable.
(2)Samples, It list “History var record”and“History group record”.
(3)Selected samples, it is a listbox,used to display selected
samples.
(4) Button functions:
l “>” : Select(alone)
l “>>”: Group select
l “↓” : Move down
l “↓↓”: Move to bottom
l “↑↑”: Move to top
l “↑” : Move up
l “<” : Remove(alone)
l “<<”: Group remove
Description:
(1)Chart type, include column bar line pie area and scatter.
(2)Chart, every type include many types. Such as column includes
common column, stack column and percent 100 stack column.
4. Generate chart preview:
Description:
(1)Header, edit chart’s header content in development.
(2)X-Axis, use it to edit chart’s x-axis’s content in development.
(3)Y-Axis, use it to edit chart’s y-axis’s content in development.
After 4 steps:
Description(row num):
No1. Report type is Class. value type is Average. Chart style
Column. LeftTop location (1,3). Picture’s size 500*350.Query time
:8,2010/10/25 8:00:00,Hour
No2. Title
No3. Binding’s query variables.
No11. Average(B4:B10), and so on.
No12. Sum(B4:B10), and so on.
Column ’E’. Max(B3:D3), and so on.
Column ‘F’. Min(B3:D3), and so on.
10.3 SubReport template design
Ø Create a report template as a sub-template and design it, as shown
in the figure below:
Ø Select the insertion location in the main report template and click "
Insert Subreport" button to insert the subreport template into the main
report template, as shown in the figure below:
Ø Select the subreport template to be inserted, and set the name of
the subreport, as shown in the figure below:
Ø The effect after insertion, as shown in the figure below:
Ø Select the subreport cell and click the "Delete SubReport"to delete
the subreport, as shown in the figure below:
Ø SubReport real-time data display and historical data query can be
realized through sub-report script.
10.4.1 How to create a real-time report
This section takes the wind turbine output real-time data report as an
example to introduce how to create real-time reports and monitor
real-time data. It is assumed that the preconditions are as follows:
Ø Project: Wind turbine output data report
Ø Window: real-time monitoring of wind turbine output
Ø Variables: Variable,Variable1 and Variable2
Variables type
Variable Analog
Variable1 Analog
Variable2 Analog
Ø IO Devices:Address、Address1、Address2
IO Address Variables
Address Variable
Address1 Variable1
Address2 Variable2
After the preconditions are completed, you can perform report-related
operations, the steps are as follows:
Step 1:Right-click the "Report" node in the project window tree, and
click "New Report" in the pop-up menu. The system will create a new
report template with the default name and rename it to "Real-time
Output Monitoring", as shown in the figure below:
Step 2:Edit in the "real-time output monitoring" template, manually
modify the cell format and size of the report, as shown in the figure:
Step 3:Bind real-time variable data, bind the system time in the first
column, as shown in the figure:
Step 4:Bind the real-time variable data, bind the variable, variable1,
and variable2 in the second, third, and fourth columns respectively,
as shown in the figure:
Step 5:The report template interface after binding is as shown in the
figure:
Step 6:Double-click the "wind turbine output real-time monitoring"
window, drag and drop a report from the toolbox extension control,
and set the "data template" to the "real-time output monitoring" report
in the properties window:
Step 7:Drag a button from the toolbox window control, set the "display
text" in the properties window to "real-time output monitoring start",
configure the left-click event for it, and the script content is shown in
the figure:
Step 8:After the configuration is complete, click the "Run" button in the
menu bar at the top of the window interface to enter the running
environment, and the running screen is as shown in the figure:
Step 9:Click the "Real-time production monitoring start" button, you
can see that a new data is refreshed every second.Such a report for
monitoring real-time data is ready.
10.4.2 How to create a historical report
This section takes the wind turbine output history report as an
example to introduce how to create history reports and monitor data.
It is assumed that the preconditions are as follows:
Ø Project: Wind turbine output data report
Ø Window: historical query of wind turbine output
Ø Variables: variable,variable1,variable2
Variables type
Variable Analog
Variable1 Analog
Variable2 Analog
Ø IO Devices:Address、Address1、Address2
IO Address Variables
Address Variable
Address1 Variable1
Address2 Variable2
Ø Historical record: RecordVariable,RecordVariable1,RecordVariable2
Storage
History record Variables Timer
mode
RecordVariable Variable Timing s1,s30,h1
RecordVariable1 Variable1 Timing s1,s30,h1
RecordVariable2 Variable2 Timing s1,s30,h1
After the preconditions are completed, report-related operations can
be performed, and the steps are as follows:
Step 1:Bind historical variable data, bind the time in the system in the
first row, as shown in the figure below:
Step 2:Bind historical variable data, bind the associated variables in
the second, third, and fourth columns respectively, RecordVariable,
RecordVariable1, and RecordVariable2.As shown in the figure
below:
Step 3:Double-click the "wind turbine output real-time monitoring"
window, drag a report from the toolbox extended control, and set the
"data template" to the "historical output query" report in the properties
window:
Step 4:Click the run button to run the window, you can select the time
range, sorting, etc. to be queried from the toolbar, as shown in the
figure below:
Step 5:The query result is the historical data record as shown in the
figure below:
Step 6:To export data, click the "Export" button on the toolbar, select
the location and name to export to EXCEL:
10.4.3 How to create a daily report
This section takes the wind turbine output daily report as an example
to introduce how to create and query daily report data. It is assumed
that the preconditions are as follows:
Ø Project: Wind turbine output data report
Ø Window: historical query of wind turbine output
Ø Variables: Variable, Variable1, wind Variable2
Variables type
Variable Analog
Variable1 Analog
Variable2 Analog
Ø IO Devices:Address、Address1、Address2
IO Address Variables
Address Variable
Address1 Variable1
Address2 Variable2
Ø Historical record: RecordVariable,RecordVariable1,RecordVariable2
Storage
History record Variables Timer
mode
RecordVariable Variable Timing s1,m1,h1
RecordVariable1 Variable1 Timing s1,m1,h1
RecordVariable2 Variable2 Timing s1,m1,h1
After the preconditions are completed, you can perform report-related
operations, the steps are as follows:
Step 1:Right-click the "Report" node in the project window tree, and
click "New Report" in the pop-up menu. The system will create a new
report template with the default name and rename it to "Wind Turbine
Production Daily Report" as shown in the figure below:
Step 2:Select "Report Wizard" in the menu bar, and the "Report
Wizard Navigation Bar" pops up as shown in the figure below:
tep 3:Configure the required type in the "Report Guide", and select
S
"day" in the "Chart Type", as shown in the figure below:
Value type, to get the amount of data at the time, so select "Spurt", as
shown in the figure below:
Start time, the time to start the calculation of the daily report, as
shown in the figure below after selection:
he benchmark rank is the default, add statistical data as needed,
T
add "average" and "sum" to row statistics, add "maxi" and "min" to
column statistics, as shown in the figure below:
Find the established variables, use keywords to search, and add the
outbound volume of wind wheel ABC group in the variable record to
the point, as shown in the figure below:
elect the type of chart to be generated, and select "Curve Chart", as
S
shown in the figure below:
enerate a preview image, change the label of the generated chart to
G
a wind turbine output daily report, as shown in the figure:
tep 4:After clicking "OK", the report template interface generated by
S
the report guide is as shown in the figure:
tep 5:After the configuration is complete, click the "Run" button in the
S
menu bar at the top of the window interface to enter the running
environment, and the running screen is as shown in the figure:
11.1 Overview
An alarm is a kind of reminder when the data acquired by the
system exceeds the warning value ,in order to prevent early
warnings for dangers that might occur during the production process
or equipment failures. Alarms have irreplacable function on system
security control in industrial automation and control systems.
During the process of using the DIAView software, when the data
of the field environment(Temperature, humidity, etc)or instruments
equipment monitored and acquired by the system exceeds the
system’s preset range, the system will use setting methods to send
alarm information and display them in the alarm window, such as
sending E-mails or alarm sounds ,so that users can know the
running status of the fied and instruments equipment immediately
and operate corresponding strategies to the alarm in order to prevent
accidents .
Other operations for alarm group:
Right-click the mouse on the new created alarm group sub-node and
operations including “New Alarm Group”, “Delete” and “Rename”
operation can be operated for the current alarm group, as shown in
the figure below:
² The meanings of each setting in the configuration window are as
follows:
Name: Alarm variable name.
Alarm variable naming rules:Refer to the naming rules for IO
variable in section “5.5.1 Create IO variable ”,and If there are alarm
variables and alarm groups under similar class nodes within the same
project, the alarm variable and alarm group names cannot be
repeated.
Associated Variables:Associate the variables created in the
project, which are the corresponding variables of the data acquired by
the system; they are the basic data source for alarms. Alarm
variables can only be configured for analog value or digital value
variables.
Alarm Level:The alarm are divided into 5 levels: Slight, Lighter,
General, Serious, Heavier.
Alarm Configuration:Sets alarm information including alarm type
,the alarm value limit and alarm text that corresponds to the alarm
levels etc.
Description: Other information for the alarm variable.
² Function button :
“Add” button:Create new alarm variable.
“Insert” button: Inserts new alarm variable on the selected row.
“Delete” button: The “Delete” button is used to delete the selected
alarm variable.
“Import” button: Imports the alarm variables from Excel to the
system.
“Export” button: Exports the alarm variables from system to
Excel.
2.Configuring alarm variable
1. Associate variable: Click the button in associated variables cell
and select the system variable to associate (only analog value and
digital value type variables can be used to set alarms), as shown in
the figure below:
2.Alarm level: Click the button and a drop-down menu will appear,
select a level, as shown in the figure below:
3. Alarm configuration: Click the button in the alarm configuration
cell and the alarm configuration window will appear; the system will
perform related configurations according to the variable type, as
shown in the figure below:
Ø Analog variable (Analog type variable) alarm configuration
Analog variables are mainly integer and real type variables; click
the button in the alarm configuration cell and the analog variable
alarm configuration window will appear, as shown in the figure below:
Analog variable alarms are divided into 4 types: Limit value alarm,
Deviation alarm,Rate of change alarm and Customer expression
alarm.Alarm Text supports multilingual configuration.
(1) Limit value alarm
The alarm will be generated when the analog value exceeds the
threshold of the alarm . There are 4 alarm thresholds for Limit value
alarms: Lowlow, low, high, higher; their alarm thresholds should be
set between the maximum value and minimum value of the variable;
its alarm threshold and principles are as shown in the figure below:
When the variable value changes, if it exceeds a certain threshold
value, over-limit alarms will occur immediately. Also, only one over-
limit alarm will occur for one variable. For example: If the variable
value exceeds the “higher alarm threshold value”, the higher alarm
will occur and not the high alarm. If it went over-limit two times, the
system will determine whether they are the same type of alarm first ;
if they are, no new alarms will occur, or else the original alarm will be
reset and then a new alarm will occur.
The deviation alarm is not selected under preset conditions, one
or two of the check boxes in front of the types can be selected
when needed. After which, the editing block behind will become
editable and “Alarm value” and “Alarm text” settings can be
performed for it:
Small deviation: Sets the Small deviation value;
Large deviation: Sets the Large deviation value;
Target value: Sets the deviation target value for when the
deviation alarm occurs; it is used together with the Large and
Small deviations. Please refer to the calculation method of the
Large and Small deviations Please refer to the “Over-limit alarm”
settings for other items.
Deadband : Sets the deviation band of the alarm threshold value,
which means that when deviation alarm occurs, if the variable
value is within the alarm threshold value ± dead band value range,
no new alarms will occur; or else the alarm will first be reset and
then a new alarm will occur.
(3) Rate of change alarm
This is the alarm that occurs when the change rate of the analog
value exceeds the value set for a period, which means that the alarm
that will occur when the variable value changes too quickly. During
software running, the changing speed of the variable value will be
calculated each time to determine whether an alarm will occur. It is
mainly used to monitor the change rate of the variable.
The rate of change alarm uses time as the unit and is divided
into 3 types: hour, minute and second. Its calculation method is
as follows:
Change rate = ((current variable value — previous variable
value) * 100) / ((time the current value was generated —
previous time the value was generated) *(maximum value of the
variable — minimum value of the variable) * value that
corresponds to the alarm type unit).
※Definition of the “the value that corresponds to the alarm type
unit” is:
If alarm type is second, the value is 1;
If alarm type is minute, the value is 60;
If alarm type is hour, the value is 3600
The change rate alarm is not selected under default conditions,
check boxes in front of the rate of change can be selected when
needed. After which, the editing block behind will become editable
and “Alarm value” and “Alarm text” settings can be performed for it:
Change rate: Sets the change rate value.
Type: Sets rate of change alarm type unit; the rate of change alarm
uses time as the unit and is divided into 3 types: hour, minute and
second.
(4) Customer expression alarm
The alarm condition of the analog quantity is set by the content of the
custom expression, and the alarm will occur when the alarm condition
is triggered.
For example, var. variable>60 Or var. variable<40;Indicates that an
alarm will be generated when the variable value is greater than 60 or
less than 40.
Limit value or deviation alarm delay: Sets a delay time (unit:
second) so that when an alarm occurs the system will not display it
immediately and instead perform a delay; if the alarm was reset or
disappeared within the delay time, that alarm might be a false alarm
and the system will clear it automatically. If the alarm still exists after
the delay time, then that alarm is a real alarm and the system will
display and record it. If a new alarm occurred within the delay time,
the delay timer will restart.
There are 4 types of digital variable alarms: On alarm, Off
alarm,displacement alarm and Customer expression alarm.
² “On”: Alarm will occur when the variable value changes from
off to on (changes from 0 to 1)
² “Off”: Alarm will occur when the variable value changes from
on to off (changes from 1 to 0)
² “Displacement”: Alarm will occur when the variable value
changes no matter whether from off to on or on to off
² “Customer expression alarm”: Alarm will occur when the
variable value reaches the alarm condition set by the
custom expression script.
11.4 Alarm window
Alarm window is used to display alarms information; once an alarm
is configured, its information must be viewed only by the alarm
window, therefore they must be used together. Once an alarm
window is drawn, it will associate with all configured alarm
information automatically without other configurations. Only the
alarm type color effect and the properties of the alarm windows need
to be configured to display, such as alarm levels. etc. When the
system runs, it will display alarm information in runtime and allows
query historic data of alarm.
Step 2: After double-clicking the “AlarmConfig”, the configuration
window will appear, as shown in the figure below:
11.5.1 Email
Configure E-mail, sound ,mobile phone SMS,Wechat and IFTTT
alarm functions for alarm and alarm groups.
E-mail:
Sends alarm information to related personnel through E-mail.
Open the “E-mail” option and the configuration steps are as
follows:
Step 1:Selected the “Send e-mail” check box; it means that the send
e-mail function is enabled when selected and the next steps of the
configuration can be performed:
Step 2: Input the E-mail address to send the alarm information in the
“Send server” field:
Step 3: Click the “Settings” button ,and the “E-mail account settings”
window will appear , as shown in the figure below (taking the 163 E-
mail server as an example):
The meanings of each configuration in the window are as follows:
l TimeInterval: Sets the time interval to send E-mails; the alarm
information will be sent once a new alarm occurs within the time
interval.
l SendServer: Configures the address and port information of the
E-mail to send .
l UserName: The login user name of the E-mail account used to
send the alarm information (which is the user name of the E-mail
set in Step 2).
l Password: The password used to login the E-mail account used
to send the alarm information (which is the password of the E-
mail set in Step 2).
l Send: Test whether the E-mail server settings are correct and
whether the E-mail can be sent; the rest result is as shown in the
figure below:
Step 4: When the E-mail account setting is complete, press the “New
” button to add the information of the user to receive alarm
information:
The meanings of each field in the configuration window are as
follows:
l User Name: User name of the recipient.
User Name naming rules:Refer to the naming rules for IO variable in
section “5.5.1 Create IO variable ”,The user names under “Email” ,
“SMS”,"Wechat" and "IFTTT" nodes cannot be repeated.
l Address: E-mail address of the recipient.
l Alarm Group: Select the alarm group in which the desired alarm
information is located.
l Alarm Type: Select the alarm type to send alarm information.
l Alarm Level: Select the alarm level to send alarm information.
l Record Type: There are 4 types: Alarm, confirm, reset and
remove; the information of the selected types will be sent and
information of the unselected types will not be sent.
l Information Format: Sets the content, order, date and time
format of the alarm information sent.
11.5.2 Sound
Configure E-mail, sound ,mobile phone SMS,Wechat and IFTTT
alarm functions for alarm and alarm groups.
Sound:
Configure the sounds to play for different alarm groups, alarm levels,
alarm types and alarm variables when alarms occur.
Its priority is: All alarms < alarm group < alarm level < alarm type <
alarm variable.
Open the “Sound” option and the configuring steps are as
follows:
Step 1: Check the “Enable sound alarm” check box. It means that the
sound alarm function is enabled and the next steps of the
configuration can be performed, as shown in the figure below:
Step 2: Configure the various contents in the “Sound Alarm Config”:
Ø All Alarm:
Sound will be used for All alarms generated by the system ;
methods that can be selected include: no sound, buzzer sound,
system sound, audio file and play audio etc.
l Silent: No sounds are played.
l Buzz: Buzzer sounds are played from the buzzer of the
computer when the system generates an alarm. When multiple
alarms are generated, the buzzer sound will sound in turns.
l SysSound: Uses the sound from the Windows system, which
include the following five sounds: “Asterisk (preset)”, “Beep”,
“Exclamation”, “Hand“,”Question”.
l SoundFile: Users can customize sound file sources so that the
selected sound file will be played when an alarm is generated.
Press the button and the sound source selection window
will appear, as shown in the figure below:
The “Add” button used to import external sound files, and press the
“Play” button allows you to listen to the file.
l PlaySound: Plays the customized sound content. Pressed the
button and the sound configuration window will appear, as
shown in the figure below:
It allows customized sound contents and it supports Chinese and
English. Select the alarm related configuration information and adjust
the sound playback order; when an alarm is generated, the system
will play sound contents in order.
Ø Alarm Group:
Configure the alarm group that need sound alarm. The “New” and
“Delete” buttons can be used to select the alarm group, and use the
button in the “Alarm group” field to select the alarm group that needs
to configure sound alarms; click the button in the “Alarm sound” field
to configure alarm sounds, as shown in the figure below:
² Select alarm group, as shown in the figure below:
² Configure the alarm occurrence sound, as shown in the figure
below:
Ø Alarm level:
Set the sound alarm when different levels of alarms occur; use the
button in the “Alarm Sound” field to configure alarm sounds, as
shown in the figure below:
Ø Alarm type:
Set the sound alarm when different types of alarms occur; use the
button in the “Alarm sound” field to configure alarm sounds, as shown
in the figure below:
Ø Alarm variables:
Configurations can be performed here for alarm variables in the
DIAView software that require additional sound alarms after an alarm
occurs, as shown in the figure below:
Configuration process for each row: First use the “New” button to add
a new alarm sound configuration row
² Alarm variable: Click the button in the row to open the alarm
variable browser and select variables to associate to alarm
viriables, as shown in the figure below:
² Alarm type: Selects the alarm type that needs sound alarm; it is
a drop-down menu.
² Alarm sound: Click the button in the row to configure the sound
to play when an alarm occurs.
² Alarm recovery sound: Click the button in the row to configure
the sound to play when an alarm recovers.
11.5.3 SMS
Configure E-mail, sound ,mobile phone SMS,Wechat and IFTTT
alarm functions for alarm and alarm groups.
SMS:
Sends the alarm information to related personnel through mobile
phone SMS.
Open the “SMS” option and the configuration steps are as
follows:
Step 1: Check the “Send messages” check box; it means that the
send SMS function is enabled and the next steps of the configuration
can be performed ,as shown in the figure below:
Step 2: Click the “Configuration” button to configure the information
to sending SMS; the “Configuration” window will appear ,as shown in
the figure below (the serial port is preset to COM3, change it to
COM1: serial transmission rate is 115200):
Step 3: Click the “Connect” button and the “Test” window will appear;
click the “Send” button to display the current status, as shown in the
figure below:
Step 4: Configure the “TargetPhoneNumber” and related information
for sending SMS; click the “Send” button to display the current status,
as shown in the figure below:
Step 5:When the mobile phone account configuration is complete,
press the “New” button to add the information for the user to receive
alarm information:
The meanings of each field in the configuration window are as
follows:
l User Name: User name of the recipient.
User Name naming rules:Refer to the naming rules for IO variable in
section “5.5.1 Create IO variable ”,The user names under “Email” ,
“SMS”,"Wechat" and "IFTTT" nodes cannot be repeated.
l Phone Number: The phone number of the recipient.
l Alarm Group: Select the alarm group in which the desired alarm
information is located.
l Alarm Type: Select the alarm type to send alarm information.
l Alarm Level: Select the alarm level to send alarm information.
l Record Type: There are 4 types: Alarm, confirm, reset and
remove; the information of the selected types will be sent and
information of the unselected types will not be sent.
l Information Format: Set the content, order, date and time format
of the alarm information to send.
11.5.4 Wechat
Configure E-mail, sound ,mobile phone SMS,Wechat and IFTTT
alarm functions for alarm and alarm groups.
Wechat:
Send the alarm information to relevant personnel through enterprise
wechat.
Open the "wechat notification" tab, and the configuration steps
are as follows:
Step 1: Check the "Enable Enterprise Wechat Notification" check box
and enter "Company ID", "Application ID" and "Application Secret" in
sequence, as shown in the figure below:
Step 2: Click the "New" button to add the user information receiving
wechat notification. The user name is "UserName" by default,as
shown in the figure below:
Step 3: Configure "User ID", as shown in the figure below:
Step 4: Configure "Alarm Group" and select the grouping of required
alarm information, as shown in the figure below:
Step 5: Other configurations remain the default, and the configuration
is completed. When an alarm is generated in "Alarm.AlarmGroup 1",
wechat notification will be triggered,as shown in the figure below:
The meanings of each field in the configuration window are as
follows:
l Company ID: Enterprise wechat number, find the path "my
enterprise" - "enterprise information" - "enterprise ID".
l Application ID: ID number displayed after successfully creating
alarm application in enterprise wechat.
l Application Secret: The key displayed after the alarm application
is successfully created in the enterprise wechat.
l User Name:Name of the user receiving wechat notification.
User Name naming rules:Refer to the naming rules for IO variable in
section “5.5.1 Create IO variable ”,The user names under “Email” ,
“SMS”,"Wechat" and "IFTTT" nodes cannot be repeated.
l User ID: The account number of the user receiving the alarm
wechat notification in the enterprise wechat address book.
l Alarm Group: Select the alarm group in which the desired
alarm information is located.
l Alarm Type: Select the alarm type to send alarm information.
l Alarm Level: Select the alarm level to send alarm information.
l Record Type: There are three types: Alarm, Responses and
Restore; The selected type information will be sent, and the
unselected type information will not be sent.
l Information Format: Set the content, order, date and time
format of the alarm information to send.
11.5.5 IFTTT
Configure E-mail, sound ,mobile phone SMS,Wechat and IFTTT
alarm functions for alarm and alarm groups.
IFTTT:
Forward the alarm message to LINE/WhatsApp/Telegram through
IFTTT.
Open the "IFTTT" tab, and the configuration steps are as
follows:
Step 1: Check the "Enable IFTTT Notification" checkbox,enable
IFTTT function,as shown in the figure below:
Step 2: Click the "New" button to add users information who
receiving IFTTT notification. The user name is "UserName" by
default, as shown in the following figure:
Step 3: Configure "Event Name" and "Key",as shown in the following
figure:
Step 4: Configure "Alarm Group". In this example, select "Alarm
Group0", as shown in the following figure:
Step 5: Other configurations remain the default and the configuration
is completed,IFTTT event notification is triggered when an alarm is
generated in "Alarm Group0":
The meanings of each field in the configuration window are as
follows:
l User Name: User name of the recipient.
User Name naming rules:Refer to the naming rules for IO variable in
section “5.5.1 Create IO variable ”,The user names under “Email” ,
“SMS”,"Wechat" and "IFTTT" nodes cannot be repeated.
l Event Name: IFTTT Event Name,it is consistent with the
Event Name configured on the IFTTT official website。
l Key: The verification code for communication with the ifttt
official website,it is obtained from the ifttt official website.
l Alarm Group: Select the alarm group in which the desired
alarm information is located.
l Alarm Type: Select the alarm type to send alarm information.
l Alarm Level: Select the alarm level to send alarm information.
l Record Type: There are 3 types: Alarm, Responses and
Restore; the information of the selected types will be sent and
information of the unselected types will not be sent.
l Information Format: Set the content, order, date and time
format of the alarm information to send.
12.1 Overview
Users authority refers to the operating and control authority that a
user has when using the DIAView ; it includes “Security zone” and
“User”. User authority management can be used to guarantee safe
and reliable operations and stable executions in order to prevent
problems such as making wrong operations, unauthorized
operations, or tampering with the project settings illegally.
Ø Setting steps
Automatic Log off Time: Time limits can be set for user authority
so that they automatically logout when the time has reached; ‘0”
means always valid
User type: Sets the user type; there areThree types of users:
SystemAdmin, Administrators and operators.
Level:Set the level difference of the same user type, the level range
is 0~9, the higher the number is, the higher the level is
Description: User related information description
Step 3: Click the “Add” button to create the user and the system will
automatically generate a default user name, as shown in the figure
below:
Rules: Contains four rules, check one or all of them, then password
characters can only be set in accordance with the rules, if the
strength verification is turned on
Step 5: Click the button in the “Password” cell and the user password
modification window will appear to allow changing of user password,
as shown in the figure below:
Step 6: Click the button in the “Security” cell and the security zone
selection window will appear for setting the security zone rights of
user operations, as shown in the figure below:
Step 7: Click the button in the “User Type” cell and select a user type
from the drop-down menu; the system’s default user type is operator,
as shown in the figure below:
Step 8:Click the button in the "Expire DateTime" cell to pop up the
expiration time configuration dialog box, select whether to enable this
function, and set the expiration time of the user's expired password
after enabled, as shown in the figure below:
Step 9:Click the button in the "User Level" cell to set the user level,
as shown in the figure below:
User Level:
l The user level is used to distinguish the level differences of the
same user type.
l Users can set the level range to 0-9. The higher the number, the
higher the level, except SystemAdmin.
l High-level users have view and edit permissions for users below
this level.
Step 2: Double click the “user type” node to open the user type
configuration interface, as shown in the figure below:
The meanings of the settings in the window are as follows:
Name: the name of the user type.
Security zone naming rules:Refer to the naming rules for IO variable
in section “5.5.1 Create IO variable ”
User type level: the level of user type, the range is 0-9, 0 is the
minimum permission, and 9 is the maximum permission.
Name text: the content displayed by user type at development time
and runtime, which supports multi language display.
Description: related description information of user type.
Step 3: Click the "Add" button to create a user type, and the system
will give the default name, as shown in the figure below:
The user type name, user type level, name text and description
information can be modified. At same time, a user type is set, the
selected user type can be deleted through the "delete" button.
Ø Usage
After setting the user type configuration interface, open the user
interface and click the "Add" button to create a new user, as shown in
the figure below:
Click the drop-down button of the user type of the new user and
select the newly created user type,as shown in the figure below:
After selection, click “Save” to complete the configuration.
13 Operation variable
Operation variables are variables used to save and record the
project variables information which operated by the user.; it is related
to events and used to record and track system variables which
operated by the users. Record information includes: variable name,
change time, value of variable before and after changes and user
information etc.
Ø Configuring steps tfor operation variables are as follows:
Step 1: In the DIAView software development environment, open the
project tree window → double click the “OperationVariable” in the
project tree to open the operation variable configuration window, as
shown in the figure below:
The meanings of each field in the window are as follows:
Name: Name of the operation variable
Operation variable naming rules:Refer to the naming rules for IO
variable in section “5.5.1 Create IO variable ”,and if there
are operation variables and operation variable groups under similar
class nodes within the same node, the operation variable and
operation variable group names cannot be repeated.
Associated Variables: The associated variable
Description:Other information for the operation variable
Step 2: Click the “Add” button to create the operation variables and
the system will automatically generate a default name, as shown in
the figure below:
Step 3: Click the button in the “Associated Variables” cell and
selected the variable to associate in the variable browser, as shown
in the figure below:
※ Each variable can only be associated to one operation variable.
After configuring the description information, the configuration of an
operation variable is complete; the “Delete” button can be used to
delete the selected operation variable and the “Import” and “Export”
buttons can be used to import and export the operation variables from
and into Excel.
Viewing operation variables: To view the information of the
operation variables, user can call the report object scripts
QueryVariableOperations(sheetIndex,opVariablePaths)
For example: Draw a report in the window: report 0 and a button:
button 0;
Configure the event for “Button 0”: Left-click and call the operation
variable query function of report 0:
Report0.QueryVariableOperations(0,"Operation")
14.1 Overview
In order to display and mintor the field site running status of
production, the DIAView software will create many variables that
associates with field site equipment to perform data interaction, and
these variables are constantly updating and changing. In order to
save important data and analy the field data to mintor productive
status and system running information .In order to increase
productive efficiency and quality and optimize the system, the data of
variables during system runnning need to be recorded; the variables
that have this function are called history variables.
The record variables in the DIAView software are divided into two
types recording methods: Timing record and changed record. Timing
record records the data of the variables in the system according to
the time interval cofigured; Changed record records the data of the
variables in the system when the variable data changes.
The meanings of each configuration in the window are as follows:
Name: Name of the record variable.
Naming rules:Refer to the naming rules for IO variable in section
“5.5.1 Create IO variable ”.
Associated Variable: Associated project variable, which are the
project variables need to be saved.
Mode: Set the recording method of data; there are 2 types:
Changed record and timing record.
Timer: Set the time interval of the recording method is “Timing
record”.
Deadband: When the associated project variable is a analog value,
set a value to form a deadband with the value of the variable to
perform data filtering.
Description: Other information for the record variable.
Step 3: Click the “Add” button to create the history record variables
and the system will automatically generate a default name, as shown
in the figure below:
Step 4: Click the button in the “Associated Variables” cell and
selected the variable need to record in the variable browser, as
shown in the figure below:
※ Each variable can only be associated to one history record
variable.
Step 5: Click the drop-down button in the “Mode” cell and select the
recording method, as shown in the figure below:
Timing: Set timer;During the operation of the system, the data of
variables in the system will be recorded according to the set timer.
Changed: The system is recorded whenever variable data changes
during operation.
The meanings of timer browser are as follows:
IsEnable: Check the checkbox to enable this timer,allow to use
multiple timer, and enable timers decide the query intervar time(if
user check "s1" and "m1",the interval time is 1 second or 1 minute).
Name: Timer name, use English alphabets, numbers, or
underscores, beginning with an English letter, with a word length of
no more than 12.
Timer Unit: the base unit of timer, now has "Second", "minute",
"hour" and "day".
Timer Coefficient:Trigger time is timer unit * timer coeffcicent(ex:
timer unit is second, timer coefficient is 1, the trigger tiem is 1
second).
Relative Time: Click the button in the “Relative Time” cell , has two
select: "Project start time" and "User_defined time", it determine the
real time of timer triggered(ex: user set a timer, trigger time is 1 day, if
select "Project start time", assume project start at "2018-1-1
12:12:12", then the real trigger time of timer is 12:12:12 every day; if
user select "User_defined time", assume the defined time is "2018-1-
1 00:00:00", then the real trigger time of timer is 00:00:00 every day).
Description: Description to this timer.
Add: Add a timer in the end of datagrid.
Insert: Insert a timer.
Delete: Delete selected timer.
OK: Save modification.
Cancel: Cancel modification.
Step 7: Deadband: If the associated variable is an analog value type,
and the record method is “Changed record”, set a value as the
deadband value to form a deadband with the value of the variable:
(current value of variable - deadband value) <= deadband <= (current
value of variable + deadband value);
Effect: Data filtering.
Principle: When the next variable value is within the deadband
range, no new values will be record and the original value will remain
the same. If it is not in the deadband range, then the record variable
value will acquire a new variable value and record it into the
database, and the deadband will also change accordingly. It will keep
looping in this way.
The “Delete” button can be used to delete the history variables
selected and the “Import” and “Export” buttons can be used to import
and export the history record variables from and into Excel.
14.3 Viewing history record variable
Once the history record variables data were saved, it requires related
display tools to view the history record variables data and analy and
operate the data. The DIAView software provides history charts and
reports to query and analy the history record variables.
Ø History chart
The history charts can draw the history record variable data within a
period into a curve and display it ; it is a graphic object. One history
record variable corresponds to one curve; multiple history record
variable curves can be configured and can be used for data
comparison and analysis. For drawing of history charts, please refer
to the chapter “7.6.2 History chart”; steps to associate history record
variables are as follows:
Step 1: After the history chart is drawn, open its property window and
click “Series” → click the button in the “SeriesCollection” bar, as
shown in the figure below:
Step 2: The “History series editor”window will appear, and then click
the “Add” button to add curves, as shown in the figure below:
The system will generate a curve with a default name; the left side
of the window is the list of curve members and the right side is the
corresponding curve property window.
Step 3: Click the button in the right of “VariablePath” bar in property
window , and the history variable collection window will appear, it will
allow you to select a history record variable to associate with the
curve, as shown in the figure below:
Ø Report
The historical data of history record variable can be presented in the
form of report.A report can present the historical data of multiple
history record variables in multiple columns. For drawing of report,
please refer to the chapter “7.6.12 Report”; steps to associate history
record variables are as follows:
Step 1: Create new report template,associate with history record
variable.
Step 3: Create two DateTimePicker in
window(DateTimePicker0,DateTimePicker1) and one button,
configure the button script as follows:
DateTimePicker0.Value=Sys.StartTime
DateTimePicker1.Value=Sys.Now
Call Report0.SetWorkSheetStartTime(0,DateTimePicker0.ValueTime)
Call Report0.SetWorkSheetEndTime(0,DateTimePicker1.ValueTime)
Call Report0.SetVarRecordRulerName(0,"s1")
Call Report0.QueryHistoryData()
※ "s1" is the Timer Name。
Step 4: Run the project,click "QueryHistoryData" button,can view
historical data in the report,as shown in the figure below:
14.4 Setting historical group
When triggering condition is triggered,history record variable data will
be saved to the configured database.
Variable group record needs to configure trigger condition、database
and history record variable.The configuration steps are as follows:
Step1: Add New Historical Group:
Right-click the “Historical Group” node in the project window tree
index and then click the “New History Variable Group” from the right-
click menu. The system will create a new history variable group with
the default name, as shown in the figure below:
Several history variable groups can be created under a historical
group
History variable group naming rules:Refer to the naming rules for IO
variable in section “5.5.1 Create IO variable ”.
Double-click the created “HistoryGroup” sub-node and open the
history variable group operation window:
Step2: Configure variable record:
Parameter:
Parameter:
Configuration conditions are divided into two type according to the
trigger style:TimeScript(start,stop,one
time,continue,weekly,monthly)and ContidionScript(value
change,while true,while false,on true and on false). The configuration
is the same as the user script.please refer to chapter "16 User script
".
15.1 Overview
In industrial production, recipe is used to provides the method and
material ratio for the elements of the product; in the DIAView
software, recipe is the collection of parameter values that
corresponds to the variables during the producing. For example, the
recipe of producting cakes lists the elements to produce the cake (for
example flour, eggs, sugar and water etc.) and the amount needed
for each element. Since different types of cakes need to be
produced, their elements won’t be the same completely ; therefore
this recipe lists all the elements that are used by these cakes, but the
amount of elements used for different cakes are different. The
following table is the cake recipe of a certain cake factory:
Chocolate Cranberry
Recipe Matcha cake
cake cake
Flour 130g 100g 150g
Cocoa
30g 0g 0g
powder
Egg 4eggs 3eggs 3eggs
White
110g 60g 50g
sugar
Salad oil 45ml 0ml 0ml
Olive oil 0ml 0ml 50ml
Raisin 25g 0g 0g
Cream 50g 0g 0g
Butter 0ml 40ml 0ml
Water 300ml 200ml 100ml
Salt 0g 1g 0g
Matcha 0g 3g 0g
Cranberry 0g 0g 100g
Recipe is the collection of various elements, and each element has
its own parameter item. In the DIAView software,the recipe are the
recipe “elements” that corresponds to the project variables ; the
parameter of each recipe item is composed by variable values.
Recipes can be the preset tables of elements value and the various
recipe items, or it can be maintained during the running of the
DIAView software.
The control “Recipe browser” in the DIAView software can be used to
view and maintain recipes; it is easy to operate and highly efficient.
15.2 Recipe configuration
Configuring recipe means defining the elements of the recipe, the
specific project and the value of the dosage; configuration steps are
as follows:
Step 1:Open the project tree index window under the DIAView
software development environment →Right-click the “Recipe” in the
project tree index and click on “New Recipe” ; the system will create a
recipe table with the default name “Recipe 0”, as shown in the figure
below:
The toolbar includes some buttons to operate the recipe table,
including “Add recipe item”, “Edit recipe item”, “Write variable value to
recipe item” and “Import recipe” etc.;
The display area of the recipe table will display the recipe data that
are already configured in the project;
The StatusBar displays related nformation of the recipe.
Ø Functions of recipe browser toolbar buttons:
Functions of recipe browser toolbar buttons please refer to the
chapter “7.6.13 RecipeBrowser”
Ø Recipe browser properties:
Recipe browser properties please refer to the chapter “7.6.13
RecipeBrowser”
Ø Recipe command:
Recipe commands can be used in event scripts to operate to the
recipe, as shown in the figure below:
The DIAView software has a built-in script editor provided for users
to write customized programs; it uses the VB Script language. VBS
is a lightweight interpreted scripting language that is easy to learn
and has powerful functions; the script editor has flexible and
intelligent reminder function that allows users to write programs more
easily, conveniently and highly efficiently.
Step 3: Click the button in the “Expression” field to open the condition
expression configuration window and set the expression, as shown in
the figure below:
Step 4: Select the trigger mode; when the setting is “One true” or
“One false”, the Time Interval must also be set (unit: milliseconds);
Step 5: Click the button in the “Script Content” field to open the script
editor and write the script program, as shown in the figure below:
16.3 Time script
Time Script is a user-defined program that is executed by the system
at startup, during operation, or when the project stops. The
configuration steps are as follows:
Step 3: Select the Trigger Mode; TimeScript must also be set when
the trigger mode is set as “Onetime”, “Continue”, “Weekly” and
“Monthly”. The figure below is the configuration window that appears
when the Trigger Mode is set as “One-time” and the button in the
“Configuration” field is pressed,as is shown in:
Step 4: Click the button in the “Script Content” field to open the script
editor and write the script program, as shown in the figure below:
16.4.1 Overview
DIAView Globle Function is to package the reusable script
code, avoid code dispersion, reduce maintenance costs and
debugging difficulties.
16.4.2 Module configuration
In global function, a module consists of a series of methods,
equivalent to a list
1. Add new module:
Step 1: Right-click on the “Script” node child node "Globle Function"
in the project window tree index and then click the “New Module” item
in the right-click menu, as shown in the figure below:
Step 2: After clicking “New Module”, the system will generate a
window sub-node under the “Global Function” node using a default
name, and the new window will be opened in the sketchpad work
area, as shown in the figure below:
2. Delete Module:
Select the module node to delete from the project window tree index
and right-click on it, then select the “Delete” item from the right-click
menu to delete the window, as shown in the figure below:
3. Rename Module:
Select the module node to rename in the project window tree index
and right-click on it, and the select the “Rename” item from the right-
click menu. The module name will become an editable status and just
input the new module name, as shown in the example in the figure
below:
² Module naming rules:Refer to the naming rules for IO variable in
section “5.5.1 Create IO variable ”
4. Encrypt Module:
Select the module node to encrypt from the project window tree index
and right-click on it, then select the “Password” item from the right-
click menu to encrypt the module, as shown in the figure below:
² Note: If module has encrypted, click "Password" is to modify
password, if new password is null, will cancel password.
5. Module Property:
Select the module node to modify property from the project window
tree index and right-click on it, then select the “Property” item from
the right-click menu to modify the module property, as shown in the
figure below:
² Note: The description of module will be displayed in script
editor, as shown in the figure below:
16.4.3 Add and use method
1. Open module view
Open module window, as shown in the figure below:
Property:
Name: Method name
Method naming rules:Naming rules:Refer to the naming rules for IO
variable in section"5.5.1 Create IO variable"
Method Type: Type of method function
Sub : Not return value.
Function: Has return vaule.
Script Content: The body of method, edit in script editor.
Description: The description of method, include function, parameter,
and return vaule.
2. Add method
Step 1: Click "Add", add new method, modify name and method type,
as shown in the figure below:
Step 2: Click button of the script content, into the script editor and
compile script, as shown in the figure below:
Step 3: Click button of the description, into the description window
and modify method description, as shown in the figure below:
Step 4: The description of method will be displayed in script editor, as
shown in the figure below:
Ø Configure the database connection name:
Name:The database connection name.
Naming rules:Refer to the naming rules for IO variable in section
“5.5.1 Create IO variable ”.
Ø Configure the database connection information:
² Oracle database configuration is as shown in the figure below:
ServerName: Enter the server name or IP address of the database
that needs to connect.
ServiceName: The service name of Oracle database.
UserName: Sets the user name for Oracle ID authentication login.
Password: Sets the user password used for Oracle ID
authentication login.
ConnectionTimeout: Sets the time for the database to switch
connection or reconnect after connection failed, and reports an error
if exceeded this time; unit: seconds.
PortNumber: Port number used by Oracle database.
TableSpace: The table space to access,if it is null,Oracle will select
the default table space.
TableName: The table name to access.
² SQLServer database configuration is as shown below:
ServerName: Enter the server name or IP address of the database
that needs to connect; click the pull-down button to search for servers
automatically within the network.When accessing a remote database,
you need to enter the PC name or IP address where the database
server is located.
Authentication: There are two methods to authentication when
logging in the server:Windows ID authentication and SQL ID
authentication;if the database is configured on a local host;When
selecting "Windows authentication", no user name and password
need to be entered. When selecting SQL authentication, you need to
enter the corresponding username and password configured in the
SQL server.
UserName: Sets the user name for SQL ID authentication login.
Password: Sets the user password used for SQL ID authentication
login.
ConnectionTimeout: Sets the time for the database to switch
connection or reconnect after connection failed, and reports an error
if exceeded this time; unit: seconds.
Connect: Tests whether it can connect to the database server.
DatabaseName: Enter the database name that need to access.
TableName: The table name to access.
² SQLServer Compact database configuration is as shown in the
figure below:
DatabaseFile: Enter the database file path and file; the button on
the right can be clicked to select the directory.
Password: Database password; left empty if the password is not
required.
Connect: Tests whether it can connect to the database.
TableName: The table name to access.
² MySQL database configuration is as shown in the figure below:
ServerName: MySQL server name or IP address.
Username: Sets the user name for My SQL ID authentication login.
Password: Sets the user password used for My SQL ID
authentication login.
ConnectionTimeout: Sets the time for the database to switch
connection or reconnect after connection failed, and reports an error
if exceeded this time; unit: seconds.
Connect:Tests whether it can connect to the database server.
DatabaseName:Enter the database name that need to access.
TableName: The table name to access.
Ø Paging : If selecting the paging, the DIAView will paging the data
into a lot of pages according to the setting paging when DIAView
reads data, only one page data is read at one time;If not, all the data
is read.Due to the large amount of data in the database , reading all
data once will take up a lot of memory,it will cause the program
lagging.
17.3 Accessing database
DIAView provides many methods to access external database, one of
the most basic method is to call the database access command to
access the database. Database access provides a rich script
commands to help user query, modify the database data.
l The left side of the language resource usage browser is the tree
index of the "Global", and the right side is the display window of
language resource references.
l In the tree index to the left, if the round symbol in front of the
language resource displays as “yellow”,it means that this language
resource is referenced. If it is “gray”, it means that it is not yet
referenced.
l Select the language resource to view from the tree index to the left,
and the language resource reference display window on the right will
display all objects in the project that uses that language resource.
They are displayed using an expanded tree index in order for users to
pinpoint the objects that actually uses this language resource.
18.4 String
String is the global function of this type of repository, the user can
customize the editing steps below:
Step 1: Select the“String” node in the project window tree index, as
shown in the figure below:
Step 2: Double click "String" node and open editor window, as shown
in the figure below:
Note: In string window, row represents resource display in different
language, column represents a kind of language, if cell content is null,
will display default language content.
Functional modules that can be converted into string resources
in DIAView include:
l All tooltip property of controls in "Window".
l Content property of text control, button control, label control,
checkBox control, comboBox control and textBox control.
l Collection property of comboBox.
l Title and x, y title of chart controls.
l Alarm content in alarm variable.
Ø The text property selects the resource
At development time, the text property can directly select an existing
string resource, as follows:
Step 1: Add a new button control in window, click button in the
content property, as shown in the figure below:
Step 2: Open content editor, as shown in the figure below:
Note: If user has create a resource in string window, cilck
"Resources" and select it, if has not create, user can click"To
Resource", system will generate a new resource in string window.
Step 3: Click "Resources", select a resource user want relation, and
click "OK", this property has globalized, as shown in the figure below:
Step 2: Double click "Image" node and open editor window, as shown
in the figure below:
Note: In image window, row represents resource display in different
language, column represents a kind of language, if cell content is null,
will display default language content.
Ø Image preview:
User can preview image when mouse move into cell, as shown in the
figure below:
User can close preview image at right menu, as shown in the figure
below:
Globalization control of image in DIAView:
l Image control
l GIFImage control
Ø Use image Resource
At development time, the image path can directly select the existing
image resources, the specific operation is as follows:
Step 1: Add a new image control in window, click button in the
imagePath property, as shown in the figure below:
Step 2: Open image window, as shown in the figure below:
Step 3: Click "Resource List", select resource to relate, as shown in
the figure below:
Ø Image properties are converted to resources
At development time, the image path can be converted to image path
resources, as follows:
Step 1: Add a new image control in window, click button in the
imagePath property, as shown in the figure below:
Step 2: Open image window, as shown in the figure below:
Step 3: Click "To Resource", select resource to relate, as shown in
the figure below:
Step 4: Click "Editor",open image resources editor and editor
resource, as shown in the figure below:
Step 5: Close image resources editor, click "OK", this image control
has globalized.
18.6 Sound
Sound is the sound resource library in the globalization function.
Users can customize it as follows
Sound preview:
User can preview sound when mouse move into cell and user can
also close preview image at right menu, as shown in the figure below:
18.7 System
System more language refers to the window in the system, according
to the text in the specified language system multilingual including
advanced control menu bar and a drop-down box content, runtime
menu bar etc. For example: system multilingual edit box has three
languages: English and Chinese traditional, is the project in the
development time and runtime can switch between the three
languages
Step 1: Select the "System" node in the project window tree index, as
shown in the figure below:
Step 2: Double click "System" node and open editor window, as
shown in the figure below:
Description
l Users of traditional Chinese and English are not allowed to modify it,
even if they export Excel changes and then import them
Ø By runtime meun:
At run time, use the shortcut key F11 to exit the full screen, and click
the language button in the menu bar to switch languages, as shown
in the figure below:
Ø By script:
² WebAPI:Check to start WebAPI;
² Server Address:WebAPI server address,the default is
localhost,this refers to the IP address of the computer where
DIAView is located;
² Port Number:The default is 9010,the range is 0-65535;
² WebAPI function needs dongle support。
² The WebAPI function requires DIAView to be run as an
administrator.。
19.3 Login
Use postman to simulate the client, send the request data to the
server and obtain the corresponding response results.
Ø Login with user name and password:
Interface address:http://{ip}:{port}/RTDB/WebAPI/Login
Username and PasswordPut in Postman's Body(x-www-form-
urlencoded),the server judges whether the username and
password are correct and decides whether to return a token.
Request mode: HttpPost
Return format:Json
Ø Example:
Step 1: Check to start WebAPI service,modify the server
address to the IP of the computer where DIAView is located, and
the port number remains the default, as shown in the following
figure:
Explain:The examples in this chapter enable the webapi
function by default.
Step 2: Set username and password in the "Authority" node in
the tree directory of the project window
Step 3:Use postman to simulate post request of client,put
username and password in the Body(x-www-form-urlencoded) of
postman,send request data to the server.
Return message:
result:OK:Indicates that the result is correct;
message:" ":Message is the requested data,token returned this
time;
errorMsg:" ":When the returned result is false, you need to
check the contents of errorMsg。
19.4 Verify the validity of token
The valid duration of a token is half an hour. After it fails, it is
necessary to obtain a valid token again.
The client needs a valid token to obtain data and operation data
from the server, so first verify the validity of the token.
Interface address:http://{ip}:
{port}/RTDB/WebAPI/ValidateToken
Return format:Json
Ø Example:
Interface address:http://{ip}:
{port}/RTDB/WebAPI/UserNames/{userTypeName}
Return format:Json
Return message:
Interface address:http://{ip}:
{port}/RTDB/WebAPI/DeviceNames
Return format:Json
Interface address:http://{ip}:
{port}/RTDB/WebAPI/GetDeviceConfig/{devicename}
Return format:Json
There are two ways to obtain the address list of device: one is to
get the address list under a specified single device, and the other is
to get the address list of all device in the project.
Interface address:http://{ip}:
{port}/RTDB/WebAPI/GetDeviceAddress/{devicename}
Return format:Json
Return format:Json
Interface address:http://{ip}:{port}/RTDB/WebAPI/AllTagsList
Return format:Json
errorMsg:" ":When the returned result is false, you need to check the
contents of errorMsg.
19.10 Get variable value
Get value of the specified variable.
Interface address:http://{ip}:{port}/RTDB/WebAPI/GetTags 或
http://{ip}:{port}/RTDB/WebAPI/GetAsyncTags
Return format:Json
errorMsg:" ":When the returned result is false, you need to check the
contents of errorMsg.
19.11 Write variable value
Updates the value of specified variable.
Interface address:http://{ip}:{port}/RTDB/WebAPI/WriteTags 或
http://{ip}:{port}/RTDB/WebAPI/WriteAsyncTags
Return format:Json
errorMsg:" ":When the returned result is false, you need to check the
contents of errorMsg.
Interface address:http://{ip}:{port}/RTDB/WebAPI/AllAlarms
Return format:Json
Interface address:http://{ip}:
{port}/RTDB/WebAPI/HistoryAlarms/{startTime}/{endTime}
Return format:Json
errorMsg:" ":When the returned result is false, you need to check the
contents of errorMsg.
20.1 Overview
The DIAView is composed of two parts,the development environment
and runtime environment.The project IO communications created in
the development environment,the graphic interfaces drawn and
scripts edited etc,can only br fully operated in the runtime
environment,including display pictures dynamically and achieve real-
time monitoring.The runtime environment of the DIAView software
can dynamically display the graphic objects,the animations and
events configured for graphic objects or window controls,achieving
information interaction and real-time controlling between the picture
and the field equipment.
20.2 Project configuration
In the DIAView, the main function of project configuration is to
configure the shortcut keys of the runtime environment, the project
runtime picture and the network configuration.
Shortcut key configuration is mainly to set keys that can be used in
the project runtime environment.
Picture configuration is to set the window to open and the display
order of the window in the project runtime environment.
Network configuration,set the communication information and display
mde of server and client.
Ø Runtime
Sets the shortcut keys in the runtime environment, as shown in the
figure below:
² Auto Fit Screen: The runtime window size will adapt
automatically to the full screen.
² Auto Run: The default project is automatically run when the
computer is started.
² Start OPC UA Server: Sets whether to start OPC UA Server at run
time.
² Configuration: Configure the OPC UA Server port number.
² Cursor: Sets the running mouse style.
² Select All: Once selected, all checkbox in the group box will be
selected.
² Prohibit key F11: In the runtime environment , prohibit F11 key to
switch to full screen mode.
² Prohibit Alt + F4: In the runtime environment , prohibit “Alt + F4”
keys to close the engineering.
² Prohibit Window Switching: In the runtime environment , prohibit
“Alt + Tab”/“ Windows key + Tab” keys to switch windows.
² Prohibit Start Menu: In the runtime environment , prohibit
“Windows” key to open the start menu.
² Disable the maximize button: In the runtime environment , the
maximize button is not available.
² Resizeable: In the runtime environment ,the interface size is
allowed to change.
² Disable Main Menu: In the runtime environment ,the system menu
will not be visible.
² Full Screen: In the runtime environment ,the screen is full screen
display.
² KeyboardSize: Sets the style of the keyboard that pops up at run
time.
² Loading Image: Sets the Image to load at startup runtime.
² Runtime Icon: Sets the Image displayed at runtime.
² Clear: Clear the selected Image.
Put the License under the C:\Program Files (x86)\DIAView\License
path,Users can customize loading pictures at startup and the icon at
runtime
Ø Window
Sets the windows to be opened and the display order of the windows
in the runtime environment, as shown in the figure below:
Select the windows that need to be opened in the project runtime
environment from the “Screen list” field, and then click the
button to add the selected windows into the “Selected windows” field;
press the button to add all windows into the “Selected window”
field. The initial windows can be one or multiple windows, the newly
added window is located at the bottom; if there are multiple windows,
the button can be used to move the screen up and the
button can be used to move the screen down.
Window display order: The windows in the “Selected windows” list
will be opened in the order from top to bottom; the window opened
last (which is the bottom-most window in the list) will be displayed at
the front-most.
Ø Web Window
Sets the web windows to be opened and the display order of the web
windows in the runtime environment, as shown in the figure below:
Select the web windows that need to be opened in the project
runtime environment from the “Window list” field, and then click the
button to add the selected web windows into the “Start
Windows” field; press the button to add all web windows into the
“Start Window” field. The initial web windows can be one or multiple
web windows, the newly added web window is located at the bottom;
if there are multiple web windows, the button can be used to
move the window up and the button can be used to move the
window down.
Web window display order: The web windows in the “Start window”
list will be opened in the order from top to bottom; the web window
opened last (which is the bottom-most web window in the list) will be
displayed at the front-most.
Ø Network
Set the IP address or computer name, port number and other related
information of the server in the Network architecture,as shown in the
figure below:
² Server Address: Enter the name or IP address of the server.
² Port Number: The recommended range is 9002,9101-9200.Use
the port number of the recommended range to facilitate unified
setting of the port number range allowed by the firewall.
² Communication Password: The password that the client needs
to use to log in to the service.
² Sync Service Time: Whether the client is allowed to set the
system time of the local machine based on the service time.
² Run Server only: By default,clicking run at development time will
start both client and service,When you check run only services,only
services are strarted.
When choosing to start the web service, the web service option is
applicable.
² Port Number: The recommended range is 80,8101-8200.
² Address IP: Select the IP address that the developer started.
² Support Https: Check to start Https publishing.
² RTSP Port Number: The recommended range is 8083-8099.
Ø WebAPI
WebAPI is a network application program interface, which contains a
wide range of functions. Through API interface, network application
can realize the capabilities of storage service, message service and
computing service, and then develop web application with powerful
functions.
² WebAPI: Check enable WebAPI.
² Server Address: Provide the server address of the WebAPI.
² Port Number: The default is 9010 and the range is 0-65535.
20.3 Introduction to the runtime environment
To execute a project,the project configuration must be performed in
advance(refer to chapter 18);once the runtime picture configuration is
finished,the runtime environment can be enabled.Steps are as
follows:
1.C/S Introduction to the runtime environment
Ø Click the main interface of the DIAView software development
environment → “Start” menu →“Run” button to enter the runtime
environment, as shown in the figure below:
Ø System prompts that a dongle is not detected, the DIAView
software runtime environment requires authorization to use:
Ø Click “Ignore” to enter the 2 hour demos (this reminder will not
appear when a dongle was purchased and used):
※ The F11 button can be used to switch to full screen mode.
Includes two menus “File” “View”“Config” and “Language”:
1.File menu items and functions:
Exit: Exits the runtime environment.
It can also be achieved by calling the window command
“HMICmd.ExitApplication()” to exit.
2.View menu items and functions:
Full screen:Full screen will display in the runtime environment.
3.Config menu items and functions:
Cancel Auto Login .
4.Language menu items and functions:
If multiple languages are configured, the language menu is displayed
in the runtime environment. Click this button to switch the runtime
language.
(2)Edit menu
Command button Function
Press this command to cancel previously
Undo executed commands and start from the last
operation.
Click this command to recover the previous
Restore undo command and start from the last
operation.
Select the text within the script editing area
Cut and click this command to delete the text
and copy it into the clipboard.
(3) Find and replace:Click this command and the dialog block will
popup as shown in the follow figure:
² Find: Enter the text to search in this edit box.
² Match case: If this item is selected, it will only display examples
that have exactly the same cases as the string content in “Find
target”.
² Search up: Select this item and it will start searching upwards
from the current location of the cursor.
² Match whole word: Select this item and only examples that
matches all words in the “Find target” string will be displayed. For
example, find “aaa” and the result will return “aaa”; it will not return
“baaa” or “aaac”.
² Replace:First enter the search content and then enter the
replace content, and then simply press the“Replace” button.
² Replace all:Enter the search content and replace content, and
then simply press the “Replace all” button.
The options of “Replace” and “Replace all” have the save
effects as the “Find” option.
(4) View menu
Command Function
(2) System tree: There are 7 groups including date and time,
conversion, format etc.; each group includes several functions.
(3) Operator tree: There are three groups including arithmetic
operator, comparison operator and logical operator. There are several
operators under every group; double-click the operator and the
operator will be entered into the script editor interface.
(4) Key words tree: Includes all keywords of the script syntax.
Double-click the keyword and it will automatically be entered into the
script editor interface.
3.Syntax highlighting
In order to allow users to edit scripts more conveniently and clearly,
the script editor will use different colors to distinguish different syntax
parts. As shown in the table below:
Content Color
Default Black
Number Purple
String Dark brown
Mathematical symbol Red
Note Green
Keyword Blue
4. Intelligent reminder function
(1) Tip reminder
When the user enters a system function and enters “(“, the automatic
reminder frame will remind the function name and parameters of that
function and also the description of the function. In the Tip reminder
frame, the bold, black parameters represents the number of the
parameter that is currently being entered.
As shown in the figure below:
(2) List box prompt
When users enter a letter, the reminder frame will automatically
display. This reminder frame lists the results of fuzzy matching letters,
including objects, properties and methods etc. As shown in the figure
below:
When the user enters “.”, the system will display the reminder frame
according to the content before the “.”; the remind frame may include
property and variable group etc. As shown in the figure below:
5.Shortcut keys
Available shortcut keys in the script editor are as follows:
Command Shortcut keys
Copy Ctrl+C
Cut Ctrl+X
Paste Ctrl+V
Select all Ctrl+A
Undo Ctrl+Z
Recover Ctrl+Y
Switch to row Ctrl+G
Find and replace Ctrl+F
One-key typesetting Alt+F8
Syntax check Alt+C
Exit Alt+F4
Font Alt+S
Display/hide output
Ctrl+O
window
Subtype Description
Variant is uninitialized. Value is 0 for numeric
Empty variables or a zero-length string ("") for string
variables.
Null Variant intentionally contains no valid data.
Boolean Contains either True or False.
Byte Contains integer in the range 0 to 255.
Integer Contains integer in the range -32,768 to 32,767.
-922,337,203,685,477.5808 to
Currency
922,337,203,685,477.5807.
Contains integer in the range -2,147,483,648 to
Long
2,147,483,647.
Contains a single-precision, floating-point number in
the range -3.402823E38 to -1.401298E-45 for
Single
negative values; 1.401298E-45 to 3.402823E38 for
positive values.
Double Contains a double-precision, floating-point number
in the range -1.79769313486232E308 to
-4.94065645841247E-324 for negative values;
4.94065645841247E-324 to
1.79769313486232E308 for positive values.
Contains a number that represents a date between
Date (Time)
January 1, 100 to December 31, 9999.
Contains a variable-length string that can be up to
String
approximately 2 billion characters in length.
Object Contains an object.
Error Contains an error number.
You can use conversion functions to convert data from one subtype
to another. In addition, the VarType function returns information
about how your data is stored within a Variant.
You can also declare a variable implicitly by simply using its name in
your script. That is not generally a good practice because you could
misspell the variable name in one or more places, causing
unexpected results when your script is run. For that reason, the
Option Explicit statement is available to require explicit declaration of
all variables. The Option Explicit statement should be the first
statement in your script.
Naming Restrictions
Variable names follow the standard rules for naming anything in
VBScript. A variable name:
Similarly, the data can be retrieved from any element using an index
into the particular array element you want. For example:
. . .
SomeVariable = A(8)
. . .
Arithmetic
Description Symbol
Exponentiation ^
Unary negation -
Multiplication *
Division /
Integer division \
Modulus arithmetic Mod
Addition +
Subtraction -
String concatenation &
Comparison
Description Symbol
Equality =
Inequality <>
Less than <
Greater than >
Less than or equal to <=
Greater than or equal to >=
Object equivalence Is
Logical
Description Symbol
Logical negation Not
Logical conjunction And
Logical disjunction Or
Logical exclusion Xor
Logical equivalence Eqv
Logical implication Imp
You can control the flow of your script with conditional statements
and looping statements. Using conditional statements, you can write
VBScript code that makes decisions and repeats actions. The
following conditional statements are available in VBScript:
If...Then...Else statement
Select Case statement
Making Decisions Using If...Then...Else
The If...Then...Else statement is used to evaluate whether a
condition is True or False and, depending on the result, to specify
one or more statements to run. Usually the condition is an
expression that uses a comparison operator to compare one value or
variable with another. For information about comparison operators,
see Comparison Operators. If...Then...Else statements can be
nested to as many levels as you need.
To run only one statement when a condition is True, use the single-
line syntax for the If...Then...Else statement. The following example
shows the single-line syntax. Notice that this example omits the Else
keyword.
Sub FixDate()
Dim myDate
myDate = #2/13/95#
If myDate < Now Then myDate = Now
End Sub
To run more than one line of code, you must use the multiple-line (or
block) syntax. This syntax includes the End If statement, as shown
in the following example:
Sub AlertUser(value)
If value = 0 Then
AlertLabel.ForeColor = vbRed
AlertLabel.Font.Bold = True
AlertLabel.Font.Italic = True
End If
End Sub
Sub ChkLastWhile()
Dim counter, myNum
counter = 0
myNum = 9
Do
myNum = myNum - 1
counter = counter + 1
Loop While myNum > 10
MsgBox "The loop made " & counter & " repetitions."
End Sub
Sub ChkLastUntil()
Dim counter, myNum
counter = 0
myNum = 1
Do
myNum = myNum + 1
counter = counter + 1
Loop Until myNum = 10
MsgBox "The loop made " & counter & " repetitions."
End Sub
Using the Step keyword, you can increase or decrease the counter
variable by the value you specify. In the following example, the
counter variable j is incremented by 2 each time the loop repeats.
When the loop is finished, the total is the sum of 2, 4, 6, 8, and 10.
Sub TwosTotal()
Dim j, total
For j = 2 To 10 Step 2
total = total + j
Next
MsgBox "The total is " & total
End Sub
You can exit any For...Next statement before the counter reaches its
end value by using the Exit For statement. Because you usually
want to exit only in certain situations, such as when an error occurs,
you should use the Exit For statement in the True statement block
of an If...Then...Else statement. If the condition is False, the loop
runs as usual.
Using For Each...Next
A For Each...Next loop is similar to a For...Next loop. Instead of
repeating the statements a specified number of times, a For
Each...Next loop repeats a group of statements for each item in a
collection of objects or for each element of an array. This is
especially helpful if you don't know how many elements are in a
collection.
In the following HTML code example, the contents of a Dictionary
object is used to place text in several text boxes.
<HTML>
<HEAD><TITLE>Forms and Elements</TITLE></HEAD>
<SCRIPT LANGUAGE="VBScript">
<!--
Sub cmdChange_OnClick
Dim d 'Create a variable
Set d = CreateObject("Scripting.Dictionary")
d.Add "0", "Athens" 'Add some keys and items
d.Add "1", "Belgrade"
d.Add "2", "Cairo"
For Each I in d
Document.frmForm.Elements(I).Value = D.Item(I)
Next
End Sub
-->
</SCRIPT>
<BODY>
<CENTER>
<FORM NAME="frmForm"
Function Celsius(fDegrees)
Celsius = (fDegrees - 32) * 5 / 9
End Function
Getting Data into and out of Procedures
Each piece of data is passed into your procedures using an
argument . Arguments serve as placeholders for the data you want
to pass into your procedure. You can name your arguments any valid
variable name. When you create a procedure using either the Sub
statement or the Function statement, parentheses must be included
after the name of the procedure. Any arguments are placed inside
these parentheses, separated by commas. For example, in the
following example, fDegrees is a placeholder for the value being
passed into the Celsius function for conversion.
Function Celsius(fDegrees)
Celsius = (fDegrees - 32) * 5 / 9
End Function
-or-
MsgBox "The Celsius temperature is " & Celsius(fDegrees) & "
degrees."
Notice that the parentheses are omitted in the call when the Call
statement isn't used.
Where Variable Is
Scope Visibility
Declared
Procedure- Event, Function, or Sub Visible in the procedure in
level procedure. which it is declared.
HEAD section of an
Visible in every procedure
Script-level HTML page, outside any
in the script.
procedure.
Variable Scope Prefixes
As script size grows, so does the value of being able to quickly
differentiate the scope of variables. A one-letter scope prefix
preceding the type prefix provides this, without unduly increasing the
size of variable names.
'*********************************************************
Function intFindUser (strUserList(), strTargetUser) Dim i '
Loop counter.
intFindUser = -1
End Function
The following table lists VBScript language features and the version
when first introduced.
Category Keywords
Array Dim, Private, Public, ReDim
IsArray
Array handling
Erase
LBound, UBound
Assignments Set
Comments Comments using ' or Rem
Empty
Nothing
Constants/Literals
Null
True, False
Do...Loop
For...Next
For Each...Next
Control flow If...Then...Else
Select Case
While...Wend
With
Conversions Abs
Asc, AscB, AscW
Chr, ChrB, ChrW
CBool, CByte
CCur, CDate
CDbl, CInt
CLng, CSng, CStr
DateSerial, DateValue
Hex, Oct
Fix, Int
Sgn
TimeSerial, TimeValue
Date, Time
DateAdd, DateDiff, DatePart
DateSerial, DateValue
Day, Month, MonthName
Dates/Times
Weekday, WeekdayName, Year
Hour, Minute, Second
Now
TimeSerial, TimeValue
Class
Const
Declarations Dim, Private, Public, ReDim
Function, Sub
Property Get, Property Let, Property Set
On Error
Error Handling
Err
Eval
Execute
Expressions RegExp
Replace
Test
FormatCurrency
FormatDateTime
Formatting Strings
FormatNumber
FormatPercent
InputBox
Input/Output LoadPicture
MsgBox
Empty
False
Literals Nothing
Null
True
Math Atn, Cos, Sin, Tan
Exp, Log, Sqr
Randomize, Rnd
Eval Function
Miscellaneous Execute Statement
RGB Function
CreateObject
Err Object
Objects
GetObject
RegExp
Addition (+), Subtraction (-)
Exponentiation (^)
Modulus arithmetic (Mod)
Multiplication (*), Division (/)
Integer Division (\)
Negation (-)
String concatenation (&)
Operators Equality (=), Inequality (<>)
Less Than (<), Less Than or Equal To
(<=)
Greater Than (>)
Greater Than or Equal To (>=)
Is
And, Or, Xor
Eqv, Imp
Options Option Explicit
Call
Procedures Function, Sub
Property Get, Property Let, Property Set
Abs
Rounding Int, Fix, Round
Sgn
ScriptEngine
ScriptEngineBuildVersion
Script Engine ID
ScriptEngineMajorVersion
ScriptEngineMinorVersion
Strings Asc, AscB, AscW
Chr, ChrB, ChrW
Filter, InStr, InStrB
InStrRev
Join
Len, LenB
LCase, UCase
Left, LeftB
Mid, MidB
Right, RightB
Replace
Space
Split
StrComp
String
StrReverse
LTrim, RTrim, Trim
IsArray
IsDate
IsEmpty
IsNull
Variants
IsNumeric
IsObject
TypeName
VarType
Category Feature/Keyword
Declarations Class
Miscellaneous Eval Execute
Objects RegExp
ScriptEngine
ScriptEngineBuildVersion
Script Engine Identification
ScriptEngineMajorVersion
ScriptEngineMinorVersion
Requirements
Version 2
Since these constants are built into VBScript, you don't have to
define them before using them. Use them anywhere in your code to
represent the values shown for each.
Requirements
Version 2
See Also
Requirements
Version 2
See Also
Requirements
Version 2
See Also
Color Constants | Comparison Constants | Date Format Constants |
Miscellaneous Constants | MsgBox Constants | String Constants |
Tristate Constants | VarType Constants
Requirements
Version 2
See Also
Color Constants | Comparison Constants | Date and Time Constants
| Miscellaneous Constants | MsgBox Constants | String Constants |
Tristate Constants | VarType Constants
Requirements
Version 2
See Also
Requirements
Version 2
See Also
Color Constants | Comparison Constants | Date and Time Constants
| Date Format Constants | Miscellaneous Constants | String
Constants | Tristate Constants | VarType Constants
Requirements
Version 2
See Also
Color Constants | Comparison Constants | Date and Time Constants
| Date Format Constants | Miscellaneous Constants | MsgBox
Constants | Tristate Constants | VarType Constants
Requirements
Version 2
See Also
Requirements
Version 2
See Also
Related Sections
Error
Description
Number
429 ActiveX component can't create object
507 An exception occurred
449 Argument not optional
17 Can't perform requested operation
430 Class doesn't support Automation
506 Class not defined
11 Division by zero
48 Error in loading DLL
5020 Expected ')' in regular expression
5019 Expected ']' in regular expression
File name or class name not found during
432
Automation operation
92 For loop not initialized
5008 Illegal assignment
51 Internal error
505 Invalid or unqualified reference
481 Invalid picture
5 Invalid procedure call or argument
5021 Invalid range in character set
94 Invalid use of Null
Error
Description
Number
448 Named argument not found
447 Object doesn't support current locale setting
445 Object doesn't support this action
438 Object doesn't support this property or method
451 Object not a collection
504 Object not safe for creating
503 Object not safe for initializing
502 Object not safe for scripting
424 Object required
91 Object variable not set
7 Out of Memory
28 Out of stack space
14 Out of string space
6 Overflow
35 Sub or function not defined
9 Subscript out of range
5017 Syntax error in regular expression
The remote server machine does not exist or is
462
unavailable
10 This array is fixed or temporarily locked
13 Type mismatch
5018 Unexpected quantifier
500 Variable is undefined
Variable uses an Automation type not supported in
458
VBScript
Wrong number of arguments or invalid property
450
assignment
See Also
Error
Description
Number
Cannot have multiple default property/method in a
1052
Class
1044 Cannot use parentheses when calling a Sub
1053 Class initialize or terminate do not have arguments
1058 'Default' specification can only be on Property Get
1057 'Default' specification must also specify 'Public'
1005 Expected '('
1006 Expected ')'
1011 Expected '='
1021 Expected 'Case'
1047 Expected 'Class'
1025 Expected end of statement
1014 Expected 'End'
1023 Expected expression
1015 Expected 'Function'
1010 Expected identifier
1012 Expected 'If'
1046 Expected 'In'
1026 Expected integer constant
1049 Expected Let or Set or Get in property declaration
Error
Description
Number
1045 Expected literal constant
1019 Expected 'Loop'
1020 Expected 'Next'
1050 Expected 'Property'
1022 Expected 'Select'
1024 Expected statement
1016 Expected 'Sub'
1017 Expected 'Then'
1013 Expected 'To'
1018 Expected 'Wend'
1027 Expected 'While' or 'Until'
1028 Expected 'While,' 'Until,' or end of statement
1029 Expected 'With'
1030 Identifier too long
1014 Invalid character
1039 Invalid 'exit' statement
1040 Invalid 'for' loop control variable
1013 Invalid number
1037 Invalid use of 'Me' keyword
1038 'loop' without 'do'
1048 Must be defined inside a Class
1042 Must be first statement on the line
1041 Name redefined
Number of arguments must be consistent across
1051
properties specification
1001 Out of Memory
1054 Property Set or Let must have at least one argument
1002 Syntax error
Error
Description
Number
1055 Unexpected 'Next'
1015 Unterminated string constant
See Also
Initialize Event
Terminate Event
Related Sections
Remarks
Requirements
Version 5
See Also
Remarks
Requirements
Version 5
See Also
Related Sections
Remarks
Requirements
Version 1
See Also
Sgn Function
Remarks
Requirements
Version 2
See Also
Dim Statement
© 2001 Microsoft Corporation. All rights reserved.
Build: Topic Version 5.6.9309.1546
Visual Basic Scripting Edition
Asc Function
Returns the ANSI character code corresponding to the first letter in a
string.
Asc(string)
Remarks
In the following example, Asc returns the ANSI character code of the
first letter of each string: Dim MyNumber MyNumber = Asc("A") '
Returns 65. MyNumber = Asc("a") ' Returns 97. MyNumber =
Asc("Apple") ' Returns 65.
Requirements
Version 1
See Also
Chr Function
Remarks
The Atn function takes the ratio of two sides of a right triangle
(number) and returns the corresponding angle in radians. The ratio is
the length of the side opposite the angle divided by the length of the
side adjacent to the angle. The range of the result is -pi /2 to pi/2
radians.
To convert degrees to radians, multiply degrees by pi/180. To convert
radians to degrees, multiply radians by 180/pi.
The following example uses Atn to calculate the value of pi:
Dim pi
pi = 4 * Atn(1) ' Calculate the value of pi.
Requirements
Version 1
See Also
Remarks
Requirements
Version 1
See Also
Remarks
Requirements
Version 1
See Also
CBool Function | CCur Function | CDate Function | CDbl Function |
CInt Function | CLng Function | CSng Function | CStr Function
Remarks
Requirements
Version 1
See Also
Remarks
Requirements
Version 1
See Also
IsDate Function
Remarks
Requirements
Version 1
See Also
CBool Function |CByte Function | CCur Function | CDate Function |
CInt Function | CLng Function | CSng Function | CStr Function
Remarks
Requirements
Version 1
See Also
Asc Function
Remarks
Note CInt differs from the Fix and Int functions, which truncate,
rather than round, the fractional part of a number. When the
fractional part is exactly 0.5, the CInt function always rounds it
to the nearest even number. For example, 0.5 rounds to 0, and
1.5 rounds to 2.
Requirements
Version 1
See Also
Remarks
Note CLng differs from the Fix and Int functions, which
truncate, rather than round, the fractional part of a number.
When the fractional part is exactly 0.5, the CLng function
always rounds it to the nearest even number. For example, 0.5
rounds to 0, and 1.5 rounds to 2.
Requirements
Version 1
See Also
Remarks
The Cos function takes an angle and returns the ratio of two sides of
a right triangle. The ratio is the length of the side adjacent to the
angle divided by the length of the hypotenuse. The result lies in the
range -1 to 1.
To convert degrees to radians, multiply degrees by pi /180. To
convert radians to degrees, multiply radians by 180/pi.
The following example uses the Cos function to return the cosine of
an angle:
Dim MyAngle, MySecant
MyAngle = 1.3 ' Define angle in radians.
MySecant = 1 / Cos(MyAngle) ' Calculate secant.
Requirements
Version 1
See Also
Arguments
servername
Required. The name of the application providing the object.
typename
Required. The type or class of the object to create.
location
Optional. The name of the network server where the object is to be
created.
Remarks
This code starts the application that creates the object (in this case,
a Microsoft Excel spreadsheet). Once an object is created, refer to it
in code using the object variable you defined. As shown in the
following example, you can access properties and methods of the
new object using the object variable, ExcelSheet, and other Excel
objects, including the Application object and the ActiveSheet.Cells
collection:
' Make Excel visible through the Application object.
ExcelSheet.Application.Visible = True
' Place some text in the first cell of the sheet.
ExcelSheet.ActiveSheet.Cells(1,1).Value = "This is column A,
row 1"
' Save the sheet.
ExcelSheet.SaveAs "C:\DOCS\TEST.XLS"
' Close Excel with the Quit method on the Application object.
ExcelSheet.Application.Quit
' Release the object variable.
Set ExcelSheet = Nothing
Requirements
Version 2
See Also
GetObject Function
© 2001 Microsoft Corporation. All rights reserved.
Build: Topic Version 5.6.9309.1546
Visual Basic Scripting Edition
CSng Function
Returns an expression that has been converted to a Variant of
subtype Single.
CSng(expression)
Remarks
In general, you can document your code using the data type
conversion functions to show that the result of some operation
should be expressed as a particular data type rather than the default
data type. For example, use CDbl or CSng to force double-precision
or single-precision arithmetic in cases where currency or integer
arithmetic normally would occur.
Use the CSng function to provide internationally aware conversions
from any other data type to a Single subtype. For example, different
decimal separators are properly recognized depending on the locale
setting of your system, as are different thousand separators.
If expression lies outside the acceptable range for the Single
subtype, an error occurs.
The following example uses the CSng function to convert a value to
a Single: Dim MyDouble1, MyDouble2, MySingle1, MySingle2 '
MyDouble1, MyDouble2 are Doubles. MyDouble1 = 75.3421115:
MyDouble2 = 75.3421555 MySingle1 = CSng(MyDouble1) '
MySingle1 contains 75.34211. MySingle2 = CSng(MyDouble2) '
MySingle2 contains 75.34216.
Requirements
Version 1
See Also
CBool Function | CByte Function | CCur Function | CDate Function |
CDbl Function | CInt Function | CLng Function | CStr Function
Remarks
In general, you can document your code using the data type
conversion functions to show that the result of some operation
should be expressed as a particular data type rather than the default
data type. For example, use CStr to force the result to be expressed
as a String.
You should use the CStr function instead of Str to provide
internationally aware conversions from any other data type to a
String subtype. For example, different decimal separators are
properly recognized depending on the locale setting of your system.
The data in expression determines what is returned according to the
following table:
Requirements
Version 1
See Also
Remarks
The following example uses the Date function to return the current
system date: Dim MyDate MyDate = Date ' MyDate contains the
current system date.
Requirements
Version 1
See Also
Arguments
interval
Required. String expression that is the interval you want to add.
See Settings section for values.
number
Required. Numeric expression that is the number of interval you
want to add. The numeric expression can either be positive, for
dates in the future, or negative, for dates in the past.
date
Required. Variant or literal representing the date to which interval
is added.
Settings
Setting Description
yyyy Year
q Quarter
m Month
y Day of year
d Day
w Weekday
ww Week of year
h Hour
n Minute
s Second
Remarks
Requirements
Version 2
See Also
Arguments
interval
Required. String expression that is the interval you want to use to
calculate the differences between date1 and date2. See Settings
section for values.
date1, date2
Required. Date expressions. Two dates you want to use in the
calculation.
firstdayofweek
Optional. Constant that specifies the day of the week. If not
specified, Sunday is assumed. See Settings section for values.
firstweekofyear
Optional. Constant that specifies the first week of the year. If not
specified, the first week is assumed to be the week in which
January 1 occurs. See Settings section for values.
Settings
Setting Description
yyyy Year
q Quarter
m Month
y Day of year
d Day
w Weekday
ww Week of year
h Hour
n Minute
s Second
The firstdayofweek argument can have the following values:
Remarks
You can use the DateDiff function to determine how many specified
time intervals exist between two dates. For example, you might use
DateDiff to calculate the number of days between two dates, or the
number of weeks between today and the end of the year.
To calculate the number of days between date1 and date2, you can
use either Day of year ("y") or Day ("d"). When interval is Weekday
("w"), DateDiff returns the number of weeks between the two dates.
If date1 falls on a Monday, DateDiff counts the number of Mondays
until date2. It counts date2 but not date1. If interval is Week ("ww"),
however, the DateDiff function returns the number of calendar
weeks between the two dates. It counts the number of Sundays
between date1 and date2. DateDiff counts date2 if it falls on a
Sunday; but it doesn't count date1, even if it does fall on a Sunday.
If date1 refers to a later point in time than date2, the DateDiff
function returns a negative number.
The firstdayofweek argument affects calculations that use the "w"
and "ww" interval symbols.
If date1 or date2 is a date literal, the specified year becomes a
permanent part of that date. However, if date1 or date2 is enclosed
in quotation marks (" ") and you omit the year, the current year is
inserted in your code each time the date1 or date2 expression is
evaluated. This makes it possible to write code that can be used in
different years.
When comparing December 31 to January 1 of the immediately
succeeding year, DateDiff for Year ("yyyy") returns 1 even though
only a day has elapsed.
The following example uses the DateDiff function to display the
number of days between a given date and today:
Function DiffADate(theDate)
DiffADate = "Days from today: " & DateDiff("d", Now,
theDate)
End Function
Requirements
Version 2
See Also
Requirements
Version 2
See Also
Arguments
year
Number between 100 and 9999, inclusive, or a numeric
expression.
month
Any numeric expression.
day
Any numeric expression.
Remarks
For the year argument, values between 0 and 99, inclusive, are
interpreted as the years 1900–1999. For all other year arguments,
use a complete four-digit year (for example, 1800).
When any argument exceeds the accepted range for that argument,
it increments to the next larger unit as appropriate. For example, if
you specify 35 days, it is evaluated as one month and some number
of days, depending on where in the year it is applied. However, if any
single argument is outside the range -32,768 to 32,767, or if the date
specified by the three arguments, either directly or by expression,
falls outside the acceptable range of dates, an error occurs.
Requirements
Version 1
See Also
Remarks
Requirements
Version 1
See Also
Requirements
Version 1
See Also
See Also
Arguments
result
Optional. Variable to which return value assignment is made. If
result is not specified, consider using the Execute statement
instead.
expression
Required. String containing any legal VBScript expression.
Remarks
The following example illustrates the use of the Eval function: Sub
GuessANumber Dim Guess, RndNum RndNum = Int((100) * Rnd(1)
+ 1) Guess = CInt(InputBox("Enter your guess:",,0)) Do If
Eval("Guess = RndNum") Then MsgBox "Congratulations! You
guessed it!" Exit Sub Else Guess = CInt(InputBox("Sorry! Try
again.",,0)) End If Loop Until Guess = 0 End Sub
Requirements
Version 5
See Also
Execute Statement
Remarks
Requirements
Version 1
See Also
Arguments
InputStrings
Required. One-dimensional array of strings to be searched.
Value
Required. String to search for.
Include
Optional. Boolean value indicating whether to return substrings that
include or exclude Value. If Include is True, Filter returns the
subset of the array that contains Value as a substring. If Include is
False, Filter returns the subset of the array that does not contain
Value as a substring.
Compare
Optional. Numeric value indicating the kind of string comparison to
use. See Settings section for values.
Settings
Remarks
Requirements
Version 2
See Also
Replace Function
Arguments
Expression
Required. Expression to be formatted.
NumDigitsAfterDecimal
Optional. Numeric value indicating how many places to the right of
the decimal are displayed. Default value is -1, which indicates that
the computer's regional settings are used.
IncludeLeadingDigit
Optional. Tristate constant that indicates whether or not a leading
zero is displayed for fractional values. See Settings section for
values.
UseParensForNegativeNumbers
Optional. Tristate constant that indicates whether or not to place
negative values within parentheses. See Settings section for
values.
GroupDigits
Optional. Tristate constant that indicates whether or not numbers
are grouped using the group delimiter specified in the computer's
regional settings. See Settings section for values.
Settings
Remarks
Requirements
Version 2
See Also
GetCurrentDate = <code><b>FormatDateTime(</b>
</code>Date<code><b>,</b></code> 1<code><b>)</b></code>
End Function
Requirements
Version 2
See Also
FormatNumberDemo = <code><b>FormatNumber(</b>
</code>MySecant<code><b>,</b></code>4<code><b>)</b>
</code> ' Format MySecant to four decimal places.
End Function
Requirements
Version 2
See Also
Arguments
Expression
Required. Expression to be formatted.
NumDigitsAfterDecimal
Optional. Numeric value indicating how many places to the right of
the decimal are displayed. Default value is -1, which indicates that
the computer's regional settings are used.
IncludeLeadingDigit
Optional. Tristate constant that indicates whether or not a leading
zero is displayed for fractional values. See Settings section for
values.
UseParensForNegativeNumbers
Optional. Tristate constant that indicates whether or not to place
negative values within parentheses. See Settings section for
values.
GroupDigits
Optional. Tristate constant that indicates whether or not numbers
are grouped using the group delimiter specified in the control
panel. See Settings section for values.
Settings
Remarks
When one or more optional arguments are omitted, the values for
the omitted arguments are provided by the computer's regional
settings.
Requirements
Version 2
See Also
Remarks
<script language="vbscript">
Dim currentLocale
' Get the current locale
currentLocale = GetLocale
Sub Button1_onclick
Dim original
original = SetLocale("en-gb")
mydate = CDate(UKDate.value)
' IE always sets the locale to US English so use the
' currentLocale variable to set the locale to US English
original = SetLocale(currentLocale)
USDate.value = FormatDateTime(mydate,vbShortDate)
End Sub
Sub button2_onclick
Dim original
original = SetLocale("de")
myvalue = CCur(GermanNumber.value)
original = SetLocale("en-gb")
USNumber.value = FormatCurrency(myvalue)
End Sub
</script>
See Also
Arguments
pathname
Optional; String. Full path and name of the file containing the object
to retrieve. If pathname is omitted, class is required.
class
Optional; String. Class of the object.
The class argument uses the syntax appname.objectype and has
these parts:
Arguments
appname
Required; String. Name of the application providing the object.
objectype
Required; String. Type or class of object to create.
Remarks
MyObject.Line 9, 90
MyObject.InsertText 9, 100, "Hello, world."
MyObject.SaveAs "C:\DRAWINGS\SAMPLE.DRW"
Note Use the GetObject function when there is a current
instance of the object or if you want to create the object with a
file already loaded. If there is no current instance, and you don't
want the object started with a file loaded, use the CreateObject
function.
Requirements
Version 5
See Also
CreateObject Function
Arguments
object
Required. Name of the object with which event is associated.
event
Required. Name of the event to which the function is to be bound.
procname
Required. String containing the name of the Sub or Function
procedure being associated with the event.
Remarks
Function GetRefTest()
Dim Splash
Splash = "GetRefTest Version 1.0" & vbCrLf
Splash = Splash & Chr(169) & " YourCompany 1999 "
MsgBox Splash
End Function
Set Window.Onload = GetRef("GetRefTest")
</SCRIPT>
Requirements
Version 5
See Also
Remarks
Requirements
Version 1
See Also
Oct Function
© 2001 Microsoft Corporation. All rights reserved.
Build: Topic Version 5.6.9309.1546
Visual Basic Scripting Edition
Hour Function
Returns a whole number between 0 and 23, inclusive, representing
the hour of the day.
Hour(time)
Requirements
Version 1
See Also
Arguments
prompt
String expression displayed as the message in the dialog box. The
maximum length of prompt is approximately 1024 characters,
depending on the width of the characters used. If prompt consists
of more than one line, you can separate the lines using a carriage
return character (Chr(13)), a linefeed character (Chr(10)), or
carriage return–linefeed character combination (Chr(13) &
Chr(10)) between each line.
title
String expression displayed in the title bar of the dialog box. If you
omit title, the application name is placed in the title bar.
default
String expression displayed in the text box as the default response
if no other input is provided. If you omit default, the text box is
displayed empty.
xpos
Numeric expression that specifies, in twips, the horizontal distance
of the left edge of the dialog box from the left edge of the screen. If
xpos is omitted, the dialog box is horizontally centered.
ypos
Numeric expression that specifies, in twips, the vertical distance of
the upper edge of the dialog box from the top of the screen. If ypos
is omitted, the dialog box is vertically positioned approximately
one-third of the way down the screen.
helpfile
String expression that identifies the Help file to use to provide
context-sensitive Help for the dialog box. If helpfile is provided,
context must also be provided.
context
Numeric expression that identifies the Help context number
assigned by the Help author to the appropriate Help topic. If
context is provided, helpfile must also be provided.
Remarks
Requirements
Version 1
See Also
MsgBox Function
MyPos = <code><b>Instr(</b></code>4<code><b>,</b></code>
SearchString<code><b>,</b></code> SearchChar<code><b>,</b>
</code> 1<code><b>)</b></code> ' A textual comparison starting
at position 4. Returns 6.
MyPos = <code><b>Instr(</b></code>1<code><b>,</b></code>
SearchString<code><b>,</b></code> SearchChar<code><b>,</b>
</code> 0<code><b>)</b></code> ' A binary comparison starting
at position 1. Returns 9.
MyPos = <code><b>Instr(</b></code>SearchString<code><b>,
</b></code> SearchChar<code><b>)</b></code> ' Comparison is
binary by default (last argument is omitted). Returns 9.
MyPos = <code><b>Instr(</b></code>1<code><b>,</b></code>
SearchString<code><b>,</b></code> "W"<code><b>)</b>
</code> ' A binary comparison starting at position 1. Returns 0
("W" is not found).
Requirements
Version 1
See Also
InStrRev Function
MyPos = <code><b>InstrRev(</b></code>SearchString<code>
<b>,</b></code> SearchChar<code><b>,</b></code> 10<code>
<b>,</b></code> 0<code><b>)</b></code> ' A binary comparison
starting at position 10. Returns 9.
MyPos = <code><b>InstrRev(</b></code>SearchString<code>
<b>,</b></code> SearchChar<code><b>,</b></code> -1<code>
<b>,</b></code> 1<code><b>)</b></code> ' A textual
comparison starting at the last position. Returns 12.
MyPos = <code><b>InstrRev(</b></code>SearchString<code>
<b>,</b></code> SearchChar<code><b>,</b></code> 8<code>
<b>)</b></code> ' Comparison is binary by default (last argument
is omitted). Returns 0.
Note The syntax for the InStrRev function is not the same as
the syntax for the InStr function.
Requirements
Version 2
See Also
InStr Function
Remarks
Both Int and Fix remove the fractional part of number and return the
resulting integer value.
The difference between Int and Fix is that if number is negative, Int
returns the first negative integer less than or equal to number,
whereas Fix returns the first negative integer greater than or equal to
number. For example, Int converts -8.4 to -9, and Fix converts -8.4
to -8.
Fix(number) is equivalent to:
Sgn(number) * Int(Abs(number))
The following examples illustrate how the Int and Fix functions
return integer portions of numbers:
MyNumber = Int(99.8) ' Returns 99.
MyNumber = Fix(99.2) ' Returns 99.
MyNumber = Int(-99.8) ' Returns -100.
MyNumber = Fix(-99.8) ' Returns -99.
MyNumber = Int(-99.2) ' Returns -100.
MyNumber = Fix(-99.2) ' Returns -99.
Requirements
Version 1
See Also
CInt Function | Round Function
Remarks
Requirements
Version 1
See Also
Remarks
Requirements
Version 1
See Also
Remarks
Requirements
Version 1
See Also
Remarks
Requirements
Version 1
See Also
Remarks
Requirements
Version 1
See Also
Remarks
Requirements
Version 1
See Also
Arguments
list
Required. One-dimensional array containing substrings to be
joined.
delimiter
Optional. String character used to separate the substrings in the
returned string. If omitted, the space character (" ") is used. If
delimiter is a zero-length string, all items in the list are
concatenated with no delimiters.
Remarks
The following example uses the Join function to join the substrings
of MyArray: Dim MyString Dim MyArray(3) MyArray(0) = "Mr."
MyArray(1) = "John " MyArray(2) = "Doe " MyArray(3) = "III"
MyString = Join(MyArray) ' MyString contains "Mr. John Doe III".
Requirements
Version 2
See Also
Split Function
Arguments
arrayname
Name of the array variable; follows standard variable naming
conventions.
dimension
Whole number indicating which dimension's lower bound is
returned. Use 1 for the first dimension, 2 for the second, and so on.
If dimension is omitted, 1 is assumed.
Remarks
Requirements
Version 1
See Also
Remarks
Requirements
Version 1
See Also
UCase Function
Arguments
string
String expression from which the leftmost characters are returned.
If string contains Null, Null is returned.
length
Numeric expression indicating how many characters to return. If 0,
a zero-length string("") is returned. If greater than or equal to the
number of characters in string, the entire string is returned.
Remarks
Requirements
Version 1
See Also
Arguments
string
Any valid string expression. If string contains Null, Null is returned.
varname
Any valid variable name. If varname contains Null, Null is returned.
Remarks
The following example uses the Len function to return the number of
characters in a string: Dim MyString MyString = Len("VBSCRIPT") '
MyString contains 8.
Requirements
Version 1
See Also
InStr Function
Remarks
Requirements
Version 2
Remarks
Requirements
Version 1
See Also
Remarks
The following example uses the LTrim, RTrim, and Trim functions to
trim leading spaces, trailing spaces, and both leading and trailing
spaces, respectively:
Dim MyVar
MyVar = LTrim(" vbscript ") ' MyVar contains "vbscript ".
MyVar = RTrim(" vbscript ") ' MyVar contains " vbscript".
MyVar = Trim(" vbscript ") ' MyVar contains "vbscript".
Requirements
Version 1
See Also
Arguments
string
String expression from which characters are returned. If string
contains Null, Null is returned.
start
Character position in string at which the part to be taken begins. If
start is greater than the number of characters in string, Mid returns
a zero-length string ("").
length
Number of characters to return. If omitted or if there are fewer than
length characters in the text (including the character at start), all
characters from the start position to the end of the string are
returned.
Remarks
Version 1
See Also
Remarks
The following example uses the Minute function to return the minute
of the hour: Dim MyVar MyVar = Minute(Now)
Requirements
Version 1
See Also
Remarks
The following example uses the Month function to return the current
month: Dim MyVar MyVar = Month(Now) ' MyVar contains the
number corresponding to ' the current month.
Requirements
Version 1
See Also
Arguments
month
Required. The numeric designation of the month. For example,
January is 1, February is 2, and so on.
abbreviate
Optional. Boolean value that indicates if the month name is to be
abbreviated. If omitted, the default is False, which means that the
month name is not abbreviated.
Remarks
Requirements
Version 2
See Also
WeekdayName Function
Requirements
Version 1
See Also
InputBox Function
Remarks
The following example uses the Now function to return the current
date and time: Dim MyVar MyVar = Now ' MyVar contains the current
date and time.
Requirements
Version 1
See Also
Remarks
Requirements
Version 1
See Also
Hex Function
© 2001 Microsoft Corporation. All rights reserved.
Build: Topic Version 5.6.9309.1546
<b>Replace(</b><a href=""
onclick="showTip(this)">expression</a><b>,</b> <a href=""
onclick="showTip(this)">find</a><b>, </b><a href=""
onclick="showTip(this)">replacewith</a>[<b>,</b> <a href=""
onclick="showTip(this)">start</a>[<b>,</b> <a href=""
onclick="showTip(this)">count</a>[<b>,</b> <a href=""
onclick="showTip(this)">compare</a>]]]<b>)</b>
Dim MyString
MyString = <code><b>Replace(</b></code>"XXpXXPXXp"
<code><b>,</b></code> "p"<code><b>,</b></code> "Y"<code>
<b>)</b></code> ' A binary comparison starting at the beginning
of the string. Returns "XXYXXPXXY".
MyString = <code><b>Replace(</b></code>"XXpXXPXXp"
<code><b>,</b></code> "p"<code><b>,</b></code> "Y"<code>
<b>,</b></code> ' A textual comparison starting at position 3.
Returns "YXXYXXY". 3<code><b>,</b></code> -1<code><b>,
</b></code> 1)
Requirements
Version 2
See Also
Filter Function
Arguments
red
Required. Number in the range 0-255 representing the red
component of the color.
green
Required. Number in the range 0-255 representing the green
component of the color.
blue
Required. Number in the range 0-255 representing the blue
component of the color.
Remarks
Version 2
Arguments
string
String expression from which the rightmost characters are
returned. If string contains Null, Null is returned.
length
Numeric expression indicating how many characters to return. If 0,
a zero-length string is returned. If greater than or equal to the
number of characters in string, the entire string is returned.
Remarks
Requirements
Version 1
See Also
Remarks
The Rnd function returns a value less than 1 but greater than or
equal to 0. The value of number determines how Rnd generates a
random number:
For any given initial seed, the same number sequence is generated
because each successive call to the Rnd function uses the previous
number as a seed for the next number in the sequence.
Before calling Rnd, use the Randomize statement without an
argument to initialize the random-number generator with a seed
based on the system timer.
To produce random integers in a given range, use this formula:
Int((upperbound - lowerbound + 1) * Rnd + lowerbound)
Here, upperbound is the highest number in the range, and
lowerbound is the lowest number in the range.
Requirements
Version 1
See Also
Randomize Statement
Arguments
expression
Required. Numeric expression being rounded.
numdecimalplaces
Optional. Number indicating how many places to the right of the
decimal are included in the rounding. If omitted, integers are
returned by the Round function.
Remarks
Requirements
Version 2
See Also
Return Values
Remarks
Requirements
Version 2
See Also
Remarks
Requirements
Version 2
See Also
Remarks
Requirements
Version 2
See Also
Remarks
Requirements
Version 2
See Also
Remarks
Requirements
Version 1
See Also
The lcid argument can be any valid 32-bit value or short string that
uniquely identifies a geographical locale. Recognized values can be
found in the Locale ID chart.
Remarks
If lcid is zero, the locale is set to match the current system setting.
A locale is a set of user preference information related to the user's
language, country/region, and cultural conventions. The locale
determines such things as keyboard layout, alphabetic sort order, as
well as date, time, number, and currency formats.
The following example illustrates the use of the SetLocale function.
To use this code, paste the entire example between the <BODY>
tags of a standard HTML page.
Enter Date in UK format: <input type="text" id="UKDate"
size="20"><p>
Here's the US equivalent: <input type="text" id="USdate"
size="20"><p>
<input type="button" value="Convert" id="button1"><p>
Enter a price in German: <input type="text"
id="GermanNumber" size="20">
<p>
Here's the UK equivalent: <input type="text" id="USNumber"
size="20"><p>
<input type="button" value="Convert" id="button2"><p>
<script language="vbscript">
Dim currentLocale
' Get the current locale
currentLocale = GetLocale
Sub Button1_onclick
Dim original
original = SetLocale("en-gb")
mydate = CDate(UKDate.value)
' IE always sets the locale to US English so use the
' currentLocale variable to set the locale to US English
original = SetLocale(currentLocale)
USDate.value = FormatDateTime(mydate,vbShortDate)
End Sub
Sub button2_onclick
Dim original
original = SetLocale("de")
myvalue = CCur(GermanNumber.value)
original = SetLocale("en-gb")
USNumber.value = FormatCurrency(myvalue)
End Sub
</script>
See Also
Return Values
Remarks
The sign of the number argument determines the return value of the
Sgn function.
The following example uses the Sgn function to determine the sign
of a number: Dim MyVar1, MyVar2, MyVar3, MySign MyVar1 = 12:
MyVar2 = -2.4: MyVar3 = 0 MySign = Sgn(MyVar1) ' Returns 1.
MySign = Sgn(MyVar2) ' Returns -1. MySign = Sgn(MyVar3) '
Returns 0.
Requirements
Version 1
See Also
Abs Function
© 2001 Microsoft Corporation. All rights reserved.
Build: Topic Version 5.6.9309.1546
Visual Basic Scripting Edition
Sleep Function
Pause specifies the number of milliseconds.
Sleep(int miliseconds)
Remarks
Requirements
Version 1
See Also
Abs Function
Remarks
The Sin function takes an angle and returns the ratio of two sides of
a right triangle. The ratio is the length of the side opposite the angle
divided by the length of the hypotenuse. The result lies in the range
-1 to 1.
To convert degrees to radians, multiply degrees by pi /180. To
convert radians to degrees, multiply radians by 180/pi.
The following example uses the Sin function to return the sine of an
angle:
Dim MyAngle, MyCosecant
MyAngle = 1.3 ' Define angle in radians.
MyCosecant = 1 / Sin(MyAngle) ' Calculate cosecant.
Requirements
Version 1
See Also
Remarks
Requirements
Version 1
See Also
String Function
Arguments
expression
Required. String expression containing substrings and delimiters. If
expression is a zero-length string, Split returns an empty array,
that is, an array with no elements and no data.
delimiter
Optional. String character used to identify substring limits. If
omitted, the space character (" ") is assumed to be the delimiter. If
delimiter is a zero-length string, a single-element array containing
the entire expression string is returned.
count
Optional. Number of substrings to be returned; -1 indicates that all
substrings are returned.
compare
Optional. Numeric value indicating the kind of comparison to use
when evaluating substrings. See Settings section for values.
Settings
Remarks
The following example uses the Split function to return an array from
a string. The function performs a textual comparison of the delimiter,
and returns all of the substrings.
Dim MyString, MyArray, Msg
MyString = "VBScriptXisXfun!"
MyArray = Split(MyString, "x", -1, 1)
' MyArray(0) contains "VBScript".
' MyArray(1) contains "is".
' MyArray(2) contains "fun!".
Msg = MyArray(0) & " " & MyArray(1)
Msg = Msg & " " & MyArray(2)
MsgBox Msg
Requirements
Version 2
See Also
Join Function
Remarks
The following example uses the Sqr function to calculate the square
root of a number: Dim MySqr MySqr = Sqr(4) ' Returns 2. MySqr =
Sqr(23) ' Returns 4.79583152331272. MySqr = Sqr(0) ' Returns 0.
MySqr = Sqr(-4) ' Generates a run-time error.
Requirements
Version 1
MyComp = <code><b>StrComp(</b></code>MyStr1<code><b>,
</b></code> MyStr2<code><b>,</b></code> 1<code><b>)</b>
</code> ' Returns 0.
MyComp = <code><b>StrComp(</b></code>MyStr1<code><b>,
</b></code> MyStr2<code><b>,</b></code> 0<code><b>)</b>
</code> ' Returns -1.
MyComp = <code><b>StrComp(</b></code>MyStr2<code><b>,
</b></code> MyStr1<code><b>)</b></code> ' Returns 1.
Requirements
Version 1
Arguments
number
Length of the returned string. If number contains Null, Null is
returned.
character
Character code specifying the character or string expression
whose first character is used to build the return string. If character
contains Null, Null is returned.
Remarks
Requirements
Version 1
See Also
Space Function
© 2001 Microsoft Corporation. All rights reserved.
Build: Topic Version 5.6.9309.1546
Visual Basic Scripting Edition
StrReverse Function
Returns a string in which the character order of a specified string is
reversed.
StrReverse(string1)
Remarks
Requirements
Version 2
Remarks
Tan takes an angle and returns the ratio of two sides of a right
triangle. The ratio is the length of the side opposite the angle divided
by the length of the side adjacent to the angle.
To convert degrees to radians, multiply degrees by pi /180. To
convert radians to degrees, multiply radians by 180/pi.
The following example uses the Tan function to return the tangent of
an angle:
Dim MyAngle, MyCotangent
MyAngle = 1.3 ' Define angle in radians.
MyCotangent = 1 / Tan(MyAngle) ' Calculate cotangent.
Requirements
Version 1
See Also
Remarks
The following example uses the Time function to return the current
system time: Dim MyTime MyTime = Time ' Return current system
time.
Requirements
Version 1
See Also
Date Function
Remarks
The following example uses the Timer function to determine the time
it takes to iterate a For...Next loop N times: Function TimeIt(N) Dim
StartTime, EndTime StartTime = Timer For I = 1 To N Next EndTime
= Timer TimeIt = EndTime - StartTime End Function
Requirements
Version 5
See Also
Randomize Statement
Arguments
hour
Number between 0 (12:00 A.M.) and 23 (11:00 P.M.), inclusive, or a
numeric expression.
minute
Any numeric expression.
second
Any numeric expression.
Remarks
When any argument exceeds the accepted range for that argument,
it increments to the next larger unit as appropriate. For example, if
you specify 75 minutes, it is evaluated as one hour and 15 minutes.
However, if any single argument is outside the range -32,768 to
32,767, or if the time specified by the three arguments, either directly
or by expression, causes the date to fall outside the acceptable
range of dates, an error occurs.
Requirements
Version 1
See Also
Remarks
You can enter valid times using a 12-hour or 24-hour clock. For
example, "2:24PM" and "14:24" are both valid time arguments. If the
time argument contains date information, TimeValue doesn't return
the date information. However, if time includes invalid date
information, an error occurs.
The following example uses the TimeValue function to convert a
string to a time. You can also use date literals to directly assign a
time to a Variant (for example, MyTime = #4:35:17 PM#).
Dim MyTime
MyTime = TimeValue("4:35:17 PM") ' MyTime contains 4:35:17
PM.
Requirements
Version 1
See Also
MyType = <code><b>TypeName(</b></code>"VBScript"<code>
<b>)</b></code> ' Returns "String".
MyType = <code><b>TypeName(</b></code>4<code><b>)</b>
</code> ' Returns "Integer".
MyType = <code><b>TypeName(</b></code>37.50<code><b>)
</b></code> ' Returns "Double".
MyType = <code><b>TypeName(</b></code>NullVar<code><b>)
</b></code> ' Returns "Null".
MyType = <code><b>TypeName(</b></code>ArrayVar<code>
<b>)</b></code> ' Returns "Variant()".
Requirements
Version 2
See Also
Arguments
arrayname
Required. Name of the array variable; follows standard variable
naming conventions.
dimension
Optional. Whole number indicating which dimension's upper bound
is returned. Use 1 for the first dimension, 2 for the second, and so
on. If dimension is omitted, 1 is assumed.
Remarks
Return
Statement
Value
UBound(A, 1) 100
UBound(A, 2) 3
UBound(A, 3) 4
Requirements
Version 1
See Also
Remarks
Requirements
Version 1
See Also
LCase Function
MyCheck = <code><b>VarType(</b></code>300<code><b>)</b>
</code> ' Returns 2.
MyCheck = <code><b>VarType(</b></code>#10/19/62#<code>
<b>)</b></code> ' Returns 7.
MyCheck = <code><b>VarType(</b></code>"VBScript"<code>
<b>)</b></code> ' Returns 8.
Requirements
Version 1
See Also
MyWeekDay = <code><b>Weekday(</b></code>MyDate<code>
<b>)</b></code> ' MyWeekDay contains 6 because MyDate
represents a Friday.
Requirements
Version 1
See Also
Requirements
Version 2
See Also
MonthName Function
Remarks
The following example uses the Year function to obtain the year from
a specified date: Dim MyDate, MyYear MyDate = #October 19,
1962# ' Assign a date. MyYear = Year(MyDate) ' MyYear contains
1962.
Requirements
Version 1
See Also
Related Sections
See Also
Null
See Also
True
Several object variables can refer to the same actual object. When
Nothing is assigned to an object variable, that variable no longer
refers to any actual object. When several object variables refer to the
same object, memory and system resources associated with the
object to which the variables refer are released only after all of them
have been set to Nothing, either explicitly using Set, or implicitly
after the last object variable set to Nothing goes out of scope.
See Also
See Also
Empty
See Also
False
Clear Method
Execute Method
Raise Method
Replace Method
Test Method
Related Sections
Remarks
Use Clear to explicitly clear the Err object after an error has been
handled. This is necessary, for example, when you use deferred
error handling with On Error Resume Next. VBScript calls the Clear
method automatically whenever any of the following statements is
executed:
Requirements
Version 1
See Also
Arguments
object
Required. Always the name of a RegExp object.
string
Required. The text string upon which the regular expression is
executed.
Remarks
The actual pattern for the regular expression search is set using the
Pattern property of the RegExp object.
The Execute method returns a Matches collection containing a
Match object for each match found in string. Execute returns an
empty Matches collection if no match is found.
The following code illustrates the use of the Execute method.
Function RegExpTest(patrn, strng)
Dim regEx, Match, Matches ' Create variable.
Set regEx = New RegExp ' Create a regular expression.
regEx.Pattern = patrn ' Set pattern.
regEx.IgnoreCase = True ' Set case insensitivity.
regEx.Global = True ' Set global applicability.
Set Matches = regEx.Execute(strng) ' Execute search.
For Each Match in Matches ' Iterate Matches collection.
RetStr = RetStr & "Match found at position "
RetStr = RetStr & Match.FirstIndex & ". Match Value is '"
RetStr = RetStr & Match.Value & "'." & vbCRLF
Next
RegExpTest = RetStr
End Function
MsgBox(RegExpTest("is.", "IS1 is2 IS3 is4"))
Requirements
Version 5
See Also
Arguments
object
Always the Err object.
number
A Long integer subtype that identifies the nature of the error.
VBScript errors (both VBScript-defined and user-defined errors)
are in the range 0–65535.
source
A string expression naming the object or application that originally
generated the error. When setting this property for an Automation
object, use the form project.class. If nothing is specified, the
programmatic ID of the current VBScript project is used.
description
A string expression describing the error. If unspecified, the value in
number is examined. If it can be mapped to a VBScript run-time
error code, a string provided by VBScript is used as description. If
there is no VBScript error corresponding to number, a generic error
message is used.
helpfile
The fully qualified path to the Help file in which help on this error
can be found. If unspecified, VBScript uses the fully qualified drive,
path, and file name of the VBScript Help file.
helpcontext
The context ID identifying a topic within helpfile that provides help
for the error. If omitted, the VBScript Help file context ID for the
error corresponding to the number property is used, if it exists.
Remarks
All the arguments are optional except number. If you use Raise,
however, without specifying some arguments, and the property
settings of the Err object contain values that have not been cleared,
those values become the values for your error.
When setting the number property to your own error code in an
Automation object, you add your error code number to the constant
vbObjectError. For example, to generate the error number 1050,
assign vbObjectError + 1050 to the number property.
The following example illustrates use of the Raise method.
On Error Resume Next
Err.Raise 6 ' Raise an overflow error.
MsgBox ("Error # " & CStr(Err.Number) & " " & Err.Description)
Err.Clear ' Clear the error.
Requirements
Version 1
See Also
Arguments
object
Required. Always the name of a RegExp object.
string1
Required. String1 is the text string in which the text replacement is
to occur.
string2
Required. String2 is the replacement text string.
Remarks
The actual pattern for the text being replaced is set using the
Pattern property of the RegExp object.
The Replace method returns a copy of string1 with the text of
RegExp.Pattern replaced with string2. If no match is found, a copy
of string1 is returned unchanged.
The following code illustrates use of the Replace method.
Function ReplaceTest(patrn, replStr)
Dim regEx, str1 ' Create variables.
str1 = "The quick brown fox jumped over the lazy dog."
Set regEx = New RegExp ' Create regular
expression.
regEx.Pattern = patrn ' Set pattern.
regEx.IgnoreCase = True ' Make case insensitive.
ReplaceTest = regEx.Replace(str1, replStr) ' Make
replacement.
End Function
Requirements
Version 5
See Also
Arguments
object
Required. Always the name of a RegExp object.
string
Required. The text string upon which the regular expression is
executed.
Remarks
The actual pattern for the regular expression search is set using the
Pattern property of the RegExp object. The RegExp.Global
property has no effect on the Test method.
The Test method returns True if a pattern match is found; False if no
match is found.
The following code illustrates the use of the Test method.
Function RegExpTest(patrn, strng)
Dim regEx, retVal ' Create variable.
Set regEx = New RegExp ' Create regular expression.
regEx.Pattern = patrn ' Set pattern.
regEx.IgnoreCase = False ' Set case sensitivity.
retVal = regEx.Test(strng) ' Execute the search test.
If retVal Then
RegExpTest = "One or more matches were found."
Else
RegExpTest = "No match was found."
End If
End Function
MsgBox(RegExpTest("is.", "IS1 is2 IS3 is4"))
Requirements
Version 5
See Also
Related Sections
See Also
See Also
Class Object
Err Object
Matches Collection
Match Object
Regular Expression (RegExp) Object
SubMatches Collection
Related Sections
Remarks
-or-
Set X = New Scripting.FileSystemObject
Events
Requirements
Version 5
See Also
Events
Initialize Event
Terminate Event
Remarks
Requirements
Version 1
See Also
For Each...Next Statement | Match Object | RegExp Object |
SubMatches Collection
Remarks
Requirements
Version 1
See Also
On Error Statement
Properties
Description Property
HelpContext Property
HelpFile Property
Number Property
Source Property
Methods
Clear Method
Raise Method
Remarks
Properties
Requirements
Version 5
See Also
Properties
FirstIndex Property
Length Property
Value Property
Remarks
Requirements
Version 5
See Also
Properties
Global Property
IgnoreCase Property
Pattern Property
Methods
Execute Method
Replace Method
Test Method
Remarks
Version 5.5
See Also
Operator Precedence
Operator Summary
Arithmetic Operators
Comparison Operators
Concatenation Operators
Logical Operators
Related Sections
Arguments
result
Any numeric variable.
expression1
Any expression.
expression2
Any expression.
Remarks
If Then
Both expressions are numeric Add.
Both expressions are strings Concatenate.
One expression is numeric and the other
Add.
is a string
Version 1
See Also
Arguments
result
Any numeric variable.
expression1
Any expression.
expression2
Any expression.
Remarks
If, and only if, both expressions evaluate to True, result is True. If
either expression evaluates to False, result is False. The following
table illustrates how result is determined:
Requirements
Version 1
See Also
Arguments
variable
Any variable or any writable property.
value
Any numeric or string literal, constant, or expression.
Remarks
The name on the left side of the equal sign can be a simple scalar
variable or an element of an array. Properties on the left side of the
equal sign can only be those properties that are writable at run time.
Requirements
Version 1
See Also
Parts
result
Any numeric variable.
expression
Any expression.
comparisonoperator
Any comparison operator.
object
Any object name.
Remarks
If Then
Both expressions are Perform a numeric comparison.
numeric
Both expressions are
Perform a string comparison.
strings
One expression is
The numeric expression is less than the
numeric and the other is a
string expression.
string
One expression is Empty Perform a numeric comparison, using 0
and the other is numeric as the Empty expression.
Perform a string comparison, using a
One expression is Empty
zero-length string ("") as the Empty
and the other is a string
expression.
Both expressions are
The expressions are equal.
Empty
Requirements
Version 1
See Also
Arguments
result
Any variable.
expression1
Any expression.
expression2
Any expression.
Remarks
Requirements
Version 1
See Also
Arguments
result
Any numeric variable.
number1
Any numeric expression.
number2
Any numeric expression.
Remarks
Requirements
Version 1
See Also
Arguments
result
Any numeric variable.
expression1
Any expression.
expression2
Any expression.
Remarks
Requirements
Version 1
See Also
Arguments
result
Any numeric variable.
number
Any numeric expression.
exponent
Any numeric expression.
Remarks
Requirements
Version 1
See Also
Arguments
result
Any numeric variable.
expression1
Any expression.
expression2
Any expression.
Remarks
Requirements
Version 1
See Also
Arguments
result
Any numeric variable.
number1
Any numeric expression.
number2
Any numeric expression.
Remarks
Requirements
Version 1
See Also
Arguments
result
Any numeric variable.
object1
Any object name.
object2
Any object name.
Remarks
If object1 and object2 both refer to the same object, result is True; if
they do not, result is False. Two variables can be made to refer to
the same object in several ways.
In the following example, A has been set to refer to the same object
as B: Set A = B
The following example makes A and B refer to the same object as C:
Set A = C Set B = C
Requirements
Version 1
See Also
Arguments
result
Any numeric variable.
number1
Any numeric expression.
number2
Any numeric expression.
Remarks
Requirements
Version 1
See Also
Arguments
result
Any numeric variable.
number1
Any numeric expression.
number2
Any numeric expression.
Remarks
Requirements
Version 1
See Also
Arguments
result
Any numeric variable.
expression
Any expression.
Remarks
In addition, the Not operator inverts the bit values of any variable
and sets the corresponding bit in result according to the following
table:
Requirements
Version 1
See Also
And Operator | Logical Operators | Operator Precedence | Operator
Summary | Or Operator | Xor Operator
Requirements
Version 1
See Also
See Also
Operator Precedence
Arguments
result
Any numeric variable.
expression1
Any expression.
expression2
Any expression.
Remarks
Requirements
Version 1
See Also
Syntax 1
result = number1-number2
Syntax 2
-number
Arguments
result
Any numeric variable.
number
Any numeric expression.
number1
Any numeric expression.
number2
Any numeric expression.
Remarks
Requirements
Version 1
See Also
Arguments
result
Any numeric variable.
expression1
Any expression.
expression2
Any expression.
Remarks
Requirements
Version 1
See Also
Description Property
FirstIndex Property
Global Property
HelpContext Property
HelpFile Property
IgnoreCase Property
Length Property
Number Property
Pattern Property
Source Property
Value Property
Related Sections
Arguments
object
Always the Err object.
stringexpression
A string expression containing a description of the error.
Remarks
Requirements
Version 1
See Also
Remarks
Requirements
Version 5
See Also
Remarks
The following code illustrates the use of the Global property (change
the value assigned to Global property to see its effect):
Function RegExpTest(patrn, strng)
Dim regEx, Match, Matches ' Create variable.
Set regEx = New RegExp ' Create a regular expression.
regEx.Pattern = patrn ' Set pattern.
regEx.IgnoreCase = True ' Set case insensitivity.
regEx.Global = True ' Set global applicability.
Set Matches = regEx.Execute(strng) ' Execute search.
For Each Match in Matches ' Iterate Matches collection.
RetStr = RetStr & "Match found at position "
RetStr = RetStr & Match.FirstIndex & ". Match Value is '"
RetStr = RetStr & Match.Value & "'." & vbCRLF
Next
RegExpTest = RetStr
End Function
MsgBox(RegExpTest("is.", "IS1 is2 IS3 is4"))
Requirements
Version 5
See Also
Arguments
object
Required. Always the Err object.
contextID
Optional. A valid identifier for a Help topic within the Help file.
Remarks
Requirements
Version 2
See Also
Description Property | HelpFile Property | Number Property | Source
Property
Applies To: Err Object
Arguments
object
Required. Always the Err object.
contextID
Optional. Fully qualified path to the Help file.
Remarks
Requirements
Version 2
See Also
Remarks
Requirements
Version 5
See Also
Remarks
Requirements
Version 5
See Also
Arguments
object
Always the Err object.
errornumber
An integer representing a VBScript error number or an SCODE
error value.
Remarks
Requirements
Version 1
See Also
Next
Requirements
Version 2
See Also
Arguments
object
Always the Err object.
stringexpression
A string expression representing the application that generated the
error.
Remarks
Requirements
Version 1
See Also
Remarks
Requirements
Version 1
See Also
Call Statement
Class Statement
Const Statement
Dim Statement
Do...Loop Statement
Erase Statement
Execute Statement
ExecuteGlobal Statement
Exit Statement
For Each...Next Statement
For...Next Statement
Function Statement
If...Then...Else Statement
On Error Statement
Option Explicit Statement
Private Statement
Property Get Statement
Property Let Statement
Property Set Statement
Public Statement
Randomize Statement
ReDim Statement
Rem Statement
Select Case Statement
Set Statement
Sub Statement
While...Wend Statement
With Statement
Related Sections
Arguments
Call
Optional keyword. If specified, you must enclose argumentlist in
parentheses. For example:
Call MyProc(0)
name
Required. Name of the procedure to call.
argumentlist
Optional. Comma-delimited list of variables, arrays, or expressions
to pass to the procedure.
Remarks
You are not required to use the Call keyword when calling a
procedure. However, if you use the Call keyword to call a procedure
that requires arguments, argumentlist must be enclosed in
parentheses. If you omit the Call keyword, you also must omit the
parentheses around argumentlist. If you use either Call syntax to call
any intrinsic or user-defined function, the function's return value is
discarded.
Call MyFunction("Hello World")
Function MyFunction(text)
MsgBox text
End Function
Requirements
Version 1
© 2001 Microsoft Corporation. All rights reserved.
Build: Topic Version 5.6.9309.1546
Visual Basic Scripting Edition
Class Statement
Declares the name of a class, as well as a definition of the variables,
properties, and methods that comprise the class.
Class name
statements
End Class
Arguments
name
Required. Name of the Class; follows standard variable naming
conventions.
statements
Required. One or more statements that define the variables,
properties, and methods of the Class.
Remarks
Requirements
Version 5
See Also
Arguments
Public
Optional. Keyword used at script level to declare constants that are
available to all procedures in all scripts. Not allowed in procedures.
Private
Optional. Keyword used at script level to declare constants that are
available only within the script where the declaration is made. Not
allowed in procedures.
constname
Required. Name of the constant; follows standard variable naming
conventions.
expression
Required. Literal or other constant, or any combination that
includes all arithmetic or logical operators except Is.
Remarks
Requirements
Version 5
See Also
Arguments
varname
Name of the variable; follows standard variable naming
conventions.
subscripts
Dimensions of an array variable; up to 60 multiple dimensions may
be declared. The subscripts argument uses the following syntax:
upperbound [,upperbound] . . .
The lower bound of an array is always zero.
Remarks
Variables declared with Dim at the script level are available to all
procedures within the script. At the procedure level, variables are
available only within the procedure.
You can also use the Dim statement with empty parentheses to
declare a dynamic array. After declaring a dynamic array, use the
ReDim statement within a procedure to define the number of
dimensions and elements in the array. If you try to redeclare a
dimension for an array variable whose size was explicitly specified in
a Dim statement, an error occurs.
The following examples illustrate the use of the Dim statement: Dim
Names(9) ' Declare an array with 10 elements. Dim Names() '
Declare a dynamic array. Dim MyVar, MyNum ' Declare two variables.
Requirements
Version 1
See Also
Arguments
condition
Numeric or string expression that is True or False. If condition is
Null, condition is treated as False.
statements
One or more statements that are repeated while or until condition is
True.
Remarks
Requirements
Version 1
See Also
Remarks
Requirements
Version 1
See Also
Remarks
Requirements
Version 1
See Also
Remarks
Requirements
Version 1
Statement Description
Provides a way to exit a Do...Loop statement. It can
be used only inside a Do...Loop statement. Exit Do
transfers control to the statement following the Loop
Exit Do
statement. When used within nested Do...Loop
statements, Exit Do transfers control to the loop that
is one nested level above the loop where it occurs.
Provides a way to exit a For loop. It can be used
only in a For...Next or For Each...Next loop. Exit
For transfers control to the statement following the
Exit For
Next statement. When used within nested For
loops, Exit For transfers control to the loop that is
one nested level above the loop where it occurs.
Immediately exits the Function procedure in which
Exit Function it appears. Execution continues with the statement
following the statement that called the Function.
Immediately exits the Property procedure in which it
appears. Execution continues with the statement
Exit Property
following the statement that called the Property
procedure.
Immediately exits the Sub procedure in which it
Exit Sub appears. Execution continues with the statement
following the statement that called the Sub.
The following example illustrates the use of the Exit statement: Sub
RandomLoop Dim I, MyNum Do ' Set up infinite loop. For I = 1 To
1000 ' Loop 1000 times. MyNum = Int(Rnd * 100) ' Generate random
numbers. Select Case MyNum ' Evaluate random number. Case 17:
MsgBox "Case 17" Exit For ' If 17, exit For...Next. Case 29: MsgBox
"Case 29" Exit Do ' If 29, exit Do...Loop. Case 54: MsgBox "Case
54" Exit Sub ' If 54, exit Sub procedure. End Select Next Loop End
Sub
Requirements
Version 1
See Also
Arguments
element
Variable used to iterate through the elements of the collection or
array. For collections, element can only be a Variant variable, a
generic Object variable, or any specific Automation object variable.
For arrays, element can only be a Variant variable.
group
Name of an object collection or array.
statements
One or more statements that are executed on each item in group.
Remarks
Requirements
Version 2
See Also
Arguments
counter
Numeric variable used as a loop counter. The variable can't be an
array element or an element of a user-defined type.
start
Initial value of counter.
end
Final value of counter.
step
Amount counter is changed each time through the loop. If not
specified, step defaults to one.
statements
One or more statements between For and Next that are executed
the specified number of times.
Remarks
Requirements
Version 1
See Also
Arguments
Public
Indicates that the Function procedure is accessible to all other
procedures in all scripts.
Default
Used only with the Public keyword in a Class block to indicate that
the Function procedure is the default method for the class. An
error occurs if more than one Default procedure is specified in a
class.
Private
Indicates that the Function procedure is accessible only to other
procedures in the script where it is declared or if the function is a
member of a class, and that the Function procedure is accessible
only to other procedures in that class.
name
Name of the Function; follows standard variable naming
conventions.
arglist
List of variables representing arguments that are passed to the
Function procedure when it is called. Commas separate multiple
variables.
statements
Any group of statements to be executed within the body of the
Function procedure.
expression
Return value of the Function.
The arglist argument has the following syntax and parts:
[ByVal | ByRef] varname[( )]
Arguments
ByVal
Indicates that the argument is passed by value.
ByRef
Indicates that the argument is passed by reference.
varname
Name of the variable representing the argument; follows standard
variable naming conventions.
Remarks
Requirements
Version 1
See Also
Arguments
condition
One or more of the following two types of expressions:
A numeric or string expression that evaluates to True or False. If
condition is Null, condition is treated as False.
An expression of the form TypeOf objectname Is objecttype. The
objectname is any object reference and objecttype is any valid
object type. The expression is True if objectname is of the object
type specified by objecttype; otherwise it is False.
statements
One or more statements separated by colons; executed if condition
is True.
condition-n
Same as condition.
elseifstatements
One or more statements executed if the associated condition-n is
True.
elsestatements
One or more statements executed if no previous condition or
condition-n expression is True.
Remarks
You can use the single-line form (first syntax) for short, simple tests.
However, the block form (second syntax) provides more structure
and flexibility than the single-line form and is usually easier to read,
maintain, and debug.
Version 1
Remarks
Requirements
Version 1
See Also
Remarks
Requirements
Version 1
Arguments
varname
Name of the variable; follows standard variable naming
conventions.
subscripts
Dimensions of an array variable; up to 60 multiple dimensions may
be declared. The subscripts argument uses the following syntax:
upper [, upper] . . .
The lower bound of an array is always zero.
Remarks
Requirements
Version 1
See Also
Arguments
Public
Indicates that the Property Get procedure is accessible to all other
procedures in all scripts.
Default
Used only with the Public keyword to indicate that the property
defined in the Property Get procedure is the default property for
the class.
Private
Indicates that the Property Get procedure is accessible only to
other procedures in the Class block where it's declared.
name
Name of the Property Get procedure; follows standard variable
naming conventions, except that the name can be the same as a
Property Let or Property Set procedure in the same Class block.
arglist
List of variables representing arguments that are passed to the
Property Get procedure when it is called. Commas separate
multiple arguments. The name of each argument in a Property Get
procedure must be the same as the corresponding argument in a
Property Let procedure (if one exists).
statements
Any group of statements to be executed within the body of the
Property Get procedure.
Set
Keyword used when assigning an object as the return value of a
Property Get procedure.
expression
Return value of the Property Get procedure.
Remarks
Requirements
Version 5
See Also
Class Statement | Dim Statement | Exit Statement | Function
Statement | Private Statement | Property Let Statement | Property
Set Statement | Public Statement | Set Statement | Sub Statement
Arguments
Public
Indicates that the Property Let procedure is accessible to all other
procedures in all scripts.
Private
Indicates that the Property Let procedure is accessible only to
other procedures in the Class block where it's declared.
name
Name of the Property Let procedure; follows standard variable
naming conventions, except that the name can be the same as a
Property Get or Property Set procedure in the same Class block.
arglist
List of variables representing arguments that are passed to the
Property Let procedure when it is called. Commas separate
multiple arguments. The name of each argument in a Property Let
procedure must be the same as the corresponding argument in a
Property Get procedure. In addition, the Property Let procedure
will always have one more argument than its corresponding
Property Get procedure. That argument is the value being
assigned to the property.
value
Variable to contain the value to be assigned to the property. When
the procedure is called, this argument appears on the right side of
the calling expression.
statements
Any group of statements to be executed within the body of the
Property Let procedure.
Remarks
Requirements
Version 5
See Also
Arguments
Public
Indicates that the Property Set procedure is accessible to all other
procedures in all scripts.
Private
Indicates that the Property Set procedure is accessible only to
other procedures in the Class block where it's declared.
name
Name of the Property Set procedure; follows standard variable
naming conventions, except that the name can be the same as a
Property Get or Property Let procedure in the same Class block.
arglist
List of variables representing arguments that are passed to the
Property Set procedure when it is called. Commas separate
multiple arguments. In addition, the Property Set procedure will
always have one more argument than its corresponding Property
Get procedure. That argument is the object being assigned to the
property.
reference
Variable containing the object reference used on the right side of
the object reference assignment.
statements
Any group of statements to be executed within the body of the
Property Set procedure.
Remarks
Requirements
Version 5
See Also
Arguments
varname
Name of the variable; follows standard variable naming
conventions.
subscripts
Dimensions of an array variable; up to 60 multiple dimensions may
be declared. The subscripts argument uses the following syntax:
upper [, upper] . . .
The lower bound of an array is always zero.
Remarks
Requirements
Version 1
See Also
Remarks
Requirements
Version 1
See Also
Arguments
Preserve
Preserves the data in an existing array when you change the size
of the last dimension.
varname
Name of the variable; follows standard variable naming
conventions.
subscripts
Dimensions of an array variable; up to 60 multiple dimensions may
be declared. The subscripts argument uses the following syntax:
upper [,upper] . . .
The lower bound of an array is always zero.
Remarks
Requirements
Version 1
See Also
-or-
' comment
Remarks
Requirements
Version 1
Arguments
testexpression
Any numeric or string expression.
expressionlist-n
Required if Case appears. Delimited list of one or more
expressions.
statements-n
One or more statements executed if testexpression matches any
part of expressionlist-n.
elsestatements-n
One or more statements executed if testexpression doesn't match
any of the Case clauses.
Remarks
Requirements
Version 1
See Also
If...Then...Else Statement
-or-
Set object.eventname = GetRef(procname)
Parameters
objectvar
Required. Name of the variable or property; follows standard
variable naming conventions.
objectexpression
Optional. Expression consisting of the name of an object, another
declared variable of the same object type, or a function or method
that returns an object of the same object type.
New
Keyword used to create a new instance of a class. If objectvar
contained a reference to an object, that reference is released when
the new one is assigned. The New keyword can only be used to
create an instance of a class.
classname
Optional. Name of the class being created. A class and its
members are defined using the Class statement.
Nothing
Optional. Discontinues association of objectvar with any specific
object or class. Assigning objectvar to Nothing releases all the
system and memory resources associated with the previously
referenced object when no other variable refers to it.
object
Required. Name of the object with which event is associated.
event
Required. Name of the event to which the function is to be bound.
procname
Required. String containing the name of the Sub or Function
being associated with the event.
Remarks
Requirements
Version 1
See Also
Arguments
Public
Indicates that the Sub procedure is accessible to all other
procedures in all scripts.
Default
Used only with the Public keyword in a Class block to indicate that
the Sub procedure is the default method for the class. An error
occurs if more than one Default procedure is specified in a class.
Private
Indicates that the Sub procedure is accessible only to other
procedures in the script where it is declared.
name
Name of the Sub; follows standard variable naming conventions.
arglist
List of variables representing arguments that are passed to the
Sub procedure when it is called. Commas separate multiple
variables.
statements
Any group of statements to be executed within the body of the Sub
procedure.
The arglist argument has the following syntax and parts:
[ByVal | ByRef] varname[( )]
Arguments
ByVal
Indicates that the argument is passed by value.
ByRef
Indicates that the argument is passed by reference.
varname
Name of the variable representing the argument; follows standard
variable naming conventions.
Remarks
Caution Sub procedures can be recursive, that is, they can call
themselves to perform a given task. However, recursion can
lead to stack overflow.
Variables used in Sub procedures fall into two categories: those that
are explicitly declared within the procedure and those that are not.
Variables that are explicitly declared in a procedure (using Dim or
the equivalent) are always local to the procedure. Variables that are
used but not explicitly declared in a procedure are also local, unless
they are explicitly declared at some higher level outside the
procedure.
Requirements
Version 1
See Also
Arguments
condition
Numeric or string expression that evaluates to True or False. If
condition is Null, condition is treated as False.
statements
One or more statements executed while condition is True.
Remarks
Requirements
Version 1
See Also
Do...Loop Statement
Arguments
object
Required. Name of an object or a function that returns an object.
statements
Required. One or more statements to be executed on object.
Remarks
You can nest With statements by placing one With block within
another. However, because members of outer With blocks are
masked within the inner With blocks, you must provide a fully
qualified object reference in an inner With block to any member of
an object in an outer With block.
Important Do not jump into or out of With blocks. If statements in a
With block are executed, but either the With or End With statement
is not executed, you may get errors or unpredictable behavior.
Requirements
Version 1
See Also
Set Statement
Example
Change the associated variables of the visibility animation of the object
into Var.VariableGroup0.Variable1
VBScript Example
Line0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
Line0.Height = 100
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
Line0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = Line0.Name
RotateAngle
Rotation Angle
Define
Double RotateAngle
Example Set the rotation Angle of the specified object to 90
VBScript Example
Line0.RotateAngle = 90
StrokeThickness
Line width
Define
Double StrokeThickness
Example Basic graphic border line width value is 5
VBScript Example
Line0.StrokeThickness = 5
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
Line0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
Line0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
Line0.Width = 100
X1
The horizontical coordinate of the starting point of the line
Define
Double X1
Example
The horizontical coordinate of the starting point of the line
VBScript Example
Line0.X1 = 0
X2
The horizontical coordinate of the ending point of the line
Define
Double X2
Example
The horizontical coordinate of the ending point of the line
VBScript Example
Line0.X2 = 100
Y1
The vertical coordinate of the starting point of the line
Define
Double Y1
Example
The vertical coordinate of the starting point of the line
VBScript Example
Line0.Y1 = 0
Y2
The vertical coordinate of the ending point of the line
Define
Double Y2
Example
The vertical coordinate of the ending point of the line
VBScript Example
Line0.Y2 = 200
ZIndex
Layer index
Define
Int32 ZIndex
Example
Set the Zindex of the specified object to 3
VBScript Example
Line0.ZIndex = 3
HMIRectangle
Rectangle control
Methods list
Name Description
Look for animation to modify the
FindAnimation
associated variables of the animation
Property list
Name Description
Fill Fill color
FillColor Fill color
Height Height
Whether show the specified object or
IsShow
not
Left The left coordinate
Name Name
Opacity Opacity
RotateAngle Rotation Angle
StrokeThickness Appearance of border line width
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
Rectangle0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
Fill
Set the fill color of controls(Colors.red)
Define
Object Fill
Example
Set the fill color of the specified object
VBScript Example
Rectangle0.Fill = Colors.red
FillColor
Gets or sets the string value of the background brush of the controls
("#FFFFFFFF")
Define
String FillColor
Example
Set the fill color of the specified object
VBScript Example
Rectangle0.FillColor = "#FFFFFFFF"
Height
Height
Define
Double Height
Example
Set the height of the specified object to 100
VBScript Example
Rectangle0.Height = 100
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
Rectangle0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = Rectangle0.Name
Opacity
Opacity
Define
Double Opacity
Example
The graphics displays translucent effect
VBScript Example
Rectangle0.Opacity = 0.5
RotateAngle
Rotation Angle
Define
Double RotateAngle
Example
Sets the rotation angle of the specified object to 90
VBScript Example
Rectangle0.RotateAngle = 90
StrokeThickness
Appearance of border line width
Define
Double StrokeThickness
Example Basic graphic border line width value is 5
VBScript Example
Rectangle0.StrokeThickness = 5
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
Rectangle0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
Rectangle0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
Rectangle0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example
Set the Zindex of the specified object to 3
VBScript Example
Rectangle0.ZIndex = 3
HMIRoundRectangle
Rounded rectangle control
Methods list
Name Description
Look for animation to modify the
FindAnimation
associated variables of the animation
Property list
Name Description
Fill Fill color
FillColor Fill color
Height Height
IsShow Whether show the specify object or not
Left The left coordinate
Name Name
Opacity Opacity
The Angle of the rounded rectangle
RadiusX
variable elliptical x radius of the circle
The Angle of the rectangular variable
RadiusY
round radius of elliptical y
RotateAngle Rotation Angle
StrokeThickness Appearance of border line width
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
RoundedRectangle0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
Fill
Set the fill color of controls(Colors.red)
Define
Object Fill
Example
Set the fill color of the specified object
VBScript Example
RoundedRectangle0.Fill = Colors.red
FillColor
Gets or sets the string("#FFFFFFFF")value of controls of the
background brush
Define
String FillColor
Example
Set the fill color of the specified object
VBScript Example
RoundedRectangle0.FillColor = "#FFFFFFFF"
Height
Height
Define
Double Height
Example
Set the height of the specified object to 100
VBScript Example
RoundedRectangle0.Height = 100
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
RoundedRectangle0.IsShow = True
RoundedRectangle0.IsShow = False
Left
The left coordinate
Define
Double Left
Example Object's left side of the coordinate values is 100 on the
screen
VBScript Example
RoundedRectangle0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = RoundedRectangle0.Name
Opacity
Opacity
Define
Double Opacity
Example
The graph displays translucent effect
VBScript Example
RoundedRectangle0.Opacity = 0.5
RadiusX
The ellipse's x radius of the rounded rectangle
Define
Double RadiusX
Example Set x radius to 45
VBScript Example
RoundedRectangle0.RadiusX = 45
RadiusY
The ellipse's y radius of the rounded rectangular
Define
Double RadiusY
Example Set y radius to 45
VBScript Example
RoundedRectangle0.RadiusY = 45
RotateAngle
Rotation Angle
Define
Double RotateAngle
Example
Set the rotation angle of the specified object to 90
VBScript Example
RoundedRectangle0.RotateAngle = 90
StrokeThickness
Appearance of border line width
Define
Double StrokeThickness
Example Basic graphic border line width value is 5
VBScript Example
RoundedRectangle0.StrokeThickness = 5
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
RoundedRectangle0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
RoundedRectangle0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
RoundedRectangle0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example
Set the Zindex of the specified object to 3
VBScript Example
RoundedRectangle0.ZIndex = 3
HMIEllipse
Ellipse control
Methods list
Name Description
Look for animation to modify the
FindAnimation
associated variables of the animation
Property list
Name Description
Fill Fill color
FillColor Fill color
Height Height
Whether show the specified object or
IsShow
not
Left The left coordinate
Name Name
Opacity Opacity
RotateAngle Rotation Angle
StrokeThickness Appearance of border line width
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
Ellipse0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
Fill
Set the fill color of controls(Colors.red)
Define
Object Fill
Example
Set the fill color of the specified object
VBScript Example
Ellipse0.Fill = Colors.red
FillColor
Gets or sets the string("#FFFFFFFF")value of controls of the
background brush
Define
String FillColor
Example
Set the fill color of the specified object
VBScript Example
Ellipse0.FillColor = "#FFFFFFFF"
Height
Height
Define
Double Height
Example
Set the height of the specified object to 100
VBScript Example
Ellipse0.Height = 100
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
Ellipse0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = RoundedRectangle0.Name
Opacity
Opacity
Define
Double Opacity
Example
The graphics displays translucent effect
VBScript Example
Ellipse0.Opacity = 0.5
RotateAngle
Rotation Angle
Define
Double RotateAngle
Example
Sets the rotation Angle of the specified object to 90
VBScript Example
Ellipse0.RotateAngle = 90
StrokeThickness
Appearance of border line width
Define
Double StrokeThickness
Example Basic graphic border line width value is 5
VBScript Example
Ellipse0.StrokeThickness = 5
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
Ellipse0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
Ellipse0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
Ellipse0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example
Set the Zindex of the specified object to 3
VBScript Example
Ellipse0.ZIndex = 3
HMIPolyLine
Polyline control
Methods list
Name Description
Look for animation to modify the
FindAnimation
associated variables of the animation
Property list
Name Description
Height Height
Whether display the specified object or
IsShow
not
Left The left coordinate
Name Name
RotateAngle Rotation Angle
StrokeThickness Line width
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
PolyLine0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
PolyLine0.Height = 100
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
PolyLine0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = PolyLine0.Name
RotateAngle
Rotation Angle
Define
Double RotateAngle
Example
Sets the rotation Angle of the specified object to 90
VBScript Example
PolyLine0.RotateAngle = 90
StrokeThickness
Line width
Define
Double StrokeThickness
Example Basic graphic border line width value is 5
VBScript Example
PolyLine0.StrokeThickness =5
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
PolyLine0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
PolyLine0.Top=100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
PolyLine0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example
Set the Zindex of the specified object to 3
VBScript Example
PolyLine0.ZIndex = 3
HMIPolygon
Polygon control
Methods list
Name Description
Look for animation to modify the
FindAnimation
associated variables of the animation
Property list
Name Description
Fill Fill color
FillColor Fill color
Height Height
Whether display the specified object or
IsShow
not
Left The left coordinate
Name Name
Opacity Opacity
RotateAngle Rotation Angle
StrokeThickness Appearance of border line width
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
Polygon0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
Fill
Set the fill color of controls(Colors.red)
Define
Object Fill
Example
Set the fill color of the specified object
VBScript Example
Polygon0.Fill = Colors.red
FillColor
Gets or sets the string value of controls of the background brush
("#FFFFFFFF")
Define
String FillColor
Example
Set the fill color of the specified object
VBScript Example
Polygon0.FillColor = "#FFFFFFFF"
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
Polygon0.Height = 100
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
Polygon0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = Polygon0.Name
Opacity
Opacity
Define
Double Opacity
Example
The graphics displays translucent effect
VBScript Example
Polygon0.Opacity = 0.5
RotateAngle
Rotation Angle
Define
Double RotateAngle
Example
Sets the rotation Angle of the specified object to 90
VBScript Example
Polygon0.RotateAngle = 90
StrokeThickness
Appearance of border line width
Define
Double StrokeThickness
Example Basic graphic border line width value is 5
VBScript Example
Polygon0.StrokeThickness = 5
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
Polygon0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
Polygon0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
Polygon0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example
Set the Zindex of the specified object to 3
VBScript Example
Polygon0.ZIndex = 3
HMIBezierCurve
Bezier curve control
Methods list
Name Description
Look for animation to modify the
FindAnimation
associated variables of the animation
Property list
Name Description
Height Height
Whether display the specified object or
IsShow
not
Left The left coordinate
Name Name
RotateAngle Rotation Angle
StrokeThickness Line width
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
BezierCurve0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
BezierCurve0.Height = 100
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
BezierCurve0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
Text0.Text = BezierCurve0.Name
RotateAngle
Rotation Angle
Define
Double RotateAngle
Example
Sets the rotation Angle of the specified object to 90
VBScript Example
BezierCurve0.RotateAngle = 90
StrokeThickness
Line width
Define
Double StrokeThickness
Example Basic graphic border line width value is 5
VBScript Example
BezierCurve0.StrokeThickness = 5
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
BezierCurve0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
BezierCurve0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
BezierCurve0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example Set the Layer index of the specified object to 2
VBScript Example
BezierCurve0.ZIndex = 2
HMIClosedCurve
Closed curve control
Methods list
Name Description
Look for animation to modify the
FindAnimation
associated variables of the animation
Property list
Name Description
Fill Fill color
FillColor Fill color
Height Height
IsShow Whether display the specified object
Left The left coordinate
Name Name
Opacity Opacity
RotateAngle Rotation Angle
StrokeThickness Line width of border
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
ClosedCurve0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
Fill
Set the fill color of controls(Colors.red)
Define
Object Fill
Example
Set the fill color of the specified object
VBScript Example
ClosedCurve0.Fill = Colors.red
FillColor
Gets or sets the string value of controls of the background brush
("#FFFFFFFF")
Define
String FillColor
Example
Set the fill color of the specified object
VBScript Example
ClosedCurve0.FillColor = "#FFFFFFFF"
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
ClosedCurve0.Height = 100
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
ClosedCurve0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
Text0.Text = ClosedCurve0.Name
Opacity
Opacity
Define
Double Opacity
Example
The graphics displays translucent effect
VBScript Example
ClosedCurve0.Opacity = 0.5
RotateAngle
Rotation Angle
Define
Double RotateAngle
Example
Sets the rotation Angle of the specified object to 90
VBScript Example
ClosedCurve0.RotateAngle = 90
StrokeThickness
Line width of border
Define
Double StrokeThickness
Example Line width of border is 5
VBScript Example
ClosedCurve0.StrokeThickness = 5
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
ClosedCurve0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
ClosedCurve0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
ClosedCurve0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example Set the Layer index of the specified object to 2
VBScript Example
ClosedCurve0.ZIndex = 2
HMIArc
Arc control
Methods list
Name Description
Look for animation to modify the
FindAnimation
associated variables of the animation
Property list
Name Description
Height Height
IsShow Whether display the specified object
Left The left coordinate
Name Name
RotateAngle Rotation Angle
StartAngle Start angle
StrokeThickness Line width of border
SweepAngle Sweep angle
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object
into Var.VariableGroup0.Variable1
VBScript Example
Arc0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
Arc0.Height = 100
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
Arc0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
Text0.Text = Arc0.Name
RotateAngle
Rotation Angle
Define
Double RotateAngle
Example
Sets the rotation Angle of the specified object to 90
VBScript Example
Arc0.RotateAngle = 90
StartAngle
Start angle
Define
Double StartAngle
Example
The Start Angle value is 90 of the circular arc
VBScript Example
Arc0.StartAngle = 90
StrokeThickness
Line width
Define
Double StrokeThickness
Example Basic graphic border line width value is 5
VBScript Example
Arc0.StrokeThickness = 5
SweepAngle
Sweep Angle
Define
Double SweepAngle
Example
Sweep Angle value is 90
VBScript Example
Arc0.SweepAngle = 90
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
Arc0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
Arc0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
Arc0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example Set the Layer index of the specified object to 2
VBScript Example
Arc0.ZIndex = 2
HMIArch
Arcuate control
Methods list
Name Description
Look for animation to modify the
FindAnimation
associated variables of the animation
Property list
Name Description
Fill Fill color
FillColor Fill color
Height Height
Whether display the specified object or
IsShow
not
Left The left coordinate
Name Name
Opacity Opacity
RotateAngle Rotation Angle
StartAngle Start angle
StrokeThickness Line width
SweepAngle Sweep Angle
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object
into Var.VariableGroup0.Variable1
VBScript Example
Arch0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
Fill
Set the fill color of controls(Colors.red)
Define
Object Fill
Example
Set the fill color of the specified object
VBScript Example
Arch0.Fill = Colors.red
FillColor
Gets or sets the string value of controls of the background brush
("#FFFFFFFF")
Define
String FillColor
Example
Set the fill color of the specified object
VBScript Example
Arch0.FillColor = "#FFFFFFFF"
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
Arch0.Height = 100
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
Arch0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
Text0.Text = Arch0.Name
Opacity
Opacity
Define
Double Opacity
Example
The graphics displays translucent effect
VBScript Example
Arch0.Opacity = 0.5
RotateAngle
Rotation Angle
Define
Double RotateAngle
Example
Sets the rotation Angle of the specified object to 90
VBScript Example
Arch0.RotateAngle = 90
StartAngle
Start angle
Define
Double StartAngle
Example
The Start Angle value is 90 of the circular arc
VBScript Example
Arch0.StartAngle = 90
StrokeThickness
Appearance of border line width
Define
Double StrokeThickness
Example Basic graphic border line width value is 5
VBScript Example
Arch0.StrokeThickness = 5
SweepAngle
Sweep Angle
Define
Double SweepAngle
Example
Sweep Angle value is 90
VBScript Example
Arch0.SweepAngle = 90
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
Arch0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
Arch0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
Arch0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example Set the Layer index of the specified object to 2
VBScript Example
Arch0.ZIndex = 2
HMIPie
Sector control
Methods list
Name Description
Look for animation to modify the
FindAnimation
associated variables of the animation
Property list
Name Description
Fill Fill color
FillColor Fill color
Height Height
Whether display the specified object or
IsShow
not
Left The left coordinate
Name Name
Opacity Opacity
RotateAngle Rotation Angle
StartAngle Start Angle
StrokeThickness Appearance of border line width
SweepAngle Sector scan Angle
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object
into Var.VariableGroup0.Variable1
VBScript Example
Pie0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
Fill
Set the fill color of the control(Colors.red)
Define
Object Fill
Example
Set the fill color of the specified object
VBScript Example
Pie0.Fill = Colors.red
FillColor
Gets or sets the string value of controls of the background brush
("#FFFFFFFF")
Define
String FillColor
Example
Set the fill color of the specified object
VBScript Example
Pie0.FillColor = "#FFFFFFFF"
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
Pie0.Height = 100
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
Pie0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
Text0.Text = Pie0.Name
Opacity
Opacity
Define
Double Opacity
Example
The graphics displays translucent effect
VBScript Example
Pie0.Opacity = 0.5
RotateAngle
Rotation Angle
Define
Double RotateAngle
Example
Set the rotation Angle of the specified object to 90
VBScript Example
Pie0.RotateAngle = 90
StartAngle
Start Angle
Define
Double StartAngle
Example
The starting Angle value of the fan is 90
VBScript Example
Pie0.StartAngle = 90
StrokeThickness
Appearance of border line width
Define
Double StrokeThickness
Example Basic graphic border line width value is 5
VBScript Example
Pie0.StrokeThickness = 5
SweepAngle
Sector scan Angle
Define
Double SweepAngle
Example
Sector scan Angle value is 90
VBScript Example
Pie0.SweepAngle = 90
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
Pie0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
Pie0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
Pie0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example Set the Layer index of the specified object to 2
VBScript Example
Pie0.ZIndex = 2
HMIPipe
Pipe control
Methods list
Name Description
Look for animation to modify the
FindAnimation
associated variables of the animation
Property list
Name Description
ForwardFlow Liquid flow direction
Height Height
Whether display the specified object or
IsShow
not
Left The left coordinate
LiquidWidth Liquid width
Name Name
PipeWidth Pipe width
RotateAngle Rotation angle
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object
into Var.VariableGroup0.Variable1
VBScript Example
Pipe0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
ForwardFlow
Liquid flow direction
Define
Boolean ForwardFlow
Example
Set the flow direction of the specified object to True
VBScript Example
Pipe0.ForwardFlow = True
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
Pipe0.Height = 100
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
Pipe0.Left = 100
LiquidWidth
Liquid width
Define
Double LiquidWidth
Example
VBScript Example
Pipe0.LiquidWidth = 30
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
Text0.Text = Pipe0.Name
PipeWidth
Pipe width
Define
Double PipeWidth
Example
Set the pipe width to 100
VBScript Example
Pipe0.PipeWidth = 100
RotateAngle
Rotation Angle
Define
Double RotateAngle
Example
Set the rotation Angle of the specified object to 90
VBScript Example
Pipe0.RotateAngle = 90
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
Pipe0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
Pipe0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
Pipe0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example Set the Layer index of the specified object to 2
VBScript Example
Pipe0.ZIndex = 2
HMIText
Text control
Methods list
Name Description
Look for animation to modify the
FindAnimation
associated variables of the animation
Property list
Name Description
FontSize Font size
Height Height
Whether display the specified object or
IsShow
not
Left The left coordinate
Name Name
Opacity Opacity
RotateAngle Rotation angle
Text The text content
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object
into Var.VariableGroup0.Variable1
VBScript Example
Text0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
FontSize
Font size
Define
Double FontSize
Example
Set the font size of the specified object
VBScript Example
Text0.FontSize = 20
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
Text0.Height = 100
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
Text0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = Text0.Name
Opacity
Opacity
Define
Double Opacity
Example
The graphics displays translucent effect
VBScript Example
Text0.Opacity = 0.5
RotateAngle
Rotation Angle
Define
Double RotateAngle
Example Set the rotation Angle of the specified object to 90
VBScript Example
Text0.RotateAngle = 90
Text
The text content
Define
String Text
Example
Set the display text
VBScript Example
Text0.Text = "SCADA"
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
Text0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
Text0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
Text0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example Set the Layer index of the specified object to 2
VBScript Example
Text0.ZIndex = 2
HMIGroup
Combinatorial graphics control
Methods list
Name Description
Look for animation to modify the
FindAnimation associated variables of the
animation
GetElementByName Get object by name
Property list
Name Description
Height Height
Whether display the specified object or
IsShow
not
Left The left coordinate
Name Name
The logical parent element of this
Parent
element
RotateAngle Rotation angle
ToolTip Tooltip text
Top The top coordinate
Width Width
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object
into Var.VariableGroup0.Variable1
VBScript Example
Group0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
GetElementByName
Get object by name
Define
GetElementByName(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of object
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
Group0.GetElementByName("Polygon18").Fill = Colors.Yellow
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
Group0.Height = 100
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
Group0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = Group0.Name
Parent
Get the logical parent element of this element
Define
HMIGroup Parent
Example
Polygon18 is one of the sub-graphics of Group0 ,Set the height of
rectangle0 to 100 in the extended properties of Group0
VBScript Example
Polygon18.Parent.Parent.Rectangle0.Height = 100
RotateAngle
Rotation Angle
Define
Double RotateAngle
Example Set the rotation Angle of the specified object to 90
VBScript Example
Group0.RotateAngle = 90
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
Group0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
Group0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
Group0.Width = 100
HMIButton
Button control
Methods list
Name Description
Look for animation to modify the
FindAnimation
associated variables of the animation
Property list
Name Description
Background The background color
BorderBrush Border color
Content Get or the set the text content of button
FontSize Font size
Foreground Foreground
Height Height
Get or set a value, the value indicating
IsEnabled
whether the control can operation
IsShow Whether display the specified object
IsTriggerOpen Whether to use the default styles
Left The left coordinate
Name Name
Opacity Opacity
RotateAngle Rotation Angle
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
Button0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
Background
The background color(Colors.Red)
Define
Object Background
Example
Set the background color of the specified object
VBScript Example
Button0.Background = Colors.Red
BorderBrush
Border color(Colors.Red)
Define
Object BorderBrush
Example
Set the border color of the specified object
VBScript Example
Button0.BorderBrush = Colors.Red
Content
Gets or sets the text content of button
Define
String Content
Example
Set the text of the specified object to "Delta SCADA"
VBScript Example
Button0.FontSize = 20
Foreground
The foreground(Colors.Red)
Define
Object Foreground
Example
Set the foreground color of the specified object
VBScript Example
Button0.Foreground = Colors.Red
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
Button0.Height = 100
IsEnabled
Gets or sets a value, the value indicating whether the control can
operation
Define
Boolean IsEnabled
Example
True :The specified object is Enabled
VBScript Example
Button0.IsEnabled = True
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
Button0.IsTriggerOpen = True
Left
The left coordinate
Define
Double Left
Example Object's left side of the coordinate values is 100 on the
screen
VBScript Example
Button0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = Button0.Name
Opacity
Opacity
Define
Double Opacity
Example
The graphics display translucent effect
VBScript Example
Button0.Opacity = 0.5
RotateAngle
Rotation Angle
Define
Double RotateAngle
Example Set the rotation Angle of the specified object to 90
VBScript Example
Button0.RotateAngle = 90
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
Button0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
Button0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
Button0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example Set the Layer index of the specified object to 3
VBScript Example
Button0.ZIndex = 3
HMICheckBox
Check box control
Methods list
Name Description
Look for animation to modify the
FindAnimation
associated variables of the animation
Property list
Name Description
Get or the set the text content of check
Content
box
FontSize Font size
Foreground Foreground
Height Height
Get or set whether the control is
IsChecked
selected
Get or set a value, the value indicating
IsEnabled
whether the control can operation
IsShow Whether display the specified object
Left The left coordinate
Name Name
Opacity Opacity
RotateAngle Rotation Angle
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
CheckBox0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
Content
Get or the set the text content of check box
Define
String Content
Example
Set the text of the specified object to "Delta SCADA"
VBScript Example
CheckBox0.FontSize = 20
Foreground
The foreground color(Colors.Red)
Define
Object Foreground
Example Set the foreground color of the specified object
VBScript Example
CheckBox0.Foreground = Colors.Red
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
CheckBox0.Height = 100
IsChecked
Gets or sets whether the control is selected
Define
Boolean IsChecked
Example
The control is selected
VBScript Example
CheckBox0.IsChecked = True
IsEnabled
Gets or sets a value, the value indicating whether the control can
operation
Define
Boolean IsEnabled
Example
True :The specified object is Enabled
VBScript Example
CheckBox0.IsEnabled = True
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
CheckBox0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = CheckBox0.Name
Opacity
Opacity
Define
Double Opacity
Example
The graphics display translucent effect
VBScript Example
CheckBox0.Opacity = 0.5
RotateAngle
Rotation Angle
Define
Double RotateAngle
Example
Set the rotation Angle of the specified object to 90
VBScript Example
CheckBox0.RotateAngle = 90
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
CheckBox0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
CheckBox0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
CheckBox0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example Set the Layer index of the specified object to 3
VBScript Example
CheckBox0.ZIndex = 3
HMIComboBox
Combo box control
Methods list
Name Description
AddItem Add item
AddItems Add items collection
ClearItems Empty the collection
Look for animation to modify the
FindAnimation
associated variables of the animation
Remove the specified items according
RemoveAtItem
to the index
RemoveItem Remove the specified items
Property list
Name Description
Background The background color
BorderBrush Border color
FontSize Font size
Foreground Foreground
Height Height
Get or set a value, the value indicating
IsEnabled
whether the control can operation
IsShow Whether display the specified object
Left The left coordinate
Name Name
Opacity Opacity
RotateAngle Rotation Angle
Select the specified item accordding to
SelectedIndex
the index
SelectedValue Select the current value
Get or the set up the Combo box text
Text
content
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
AddItem
Add item
Define
AddItem(item)
Parameter
Data
Name Required/Optional Description
Type
item Required String to add items
ComboBox0.AddItem("a")
AddItems
Add items collection
Define
AddItems(items)
Parameter
Data
Name Required/Optional Description
Type
To add items, separated by
items required String
commas
ComboBox0.AddItems("a,b,c")
ComboBox0.AddItems(UserCmd.GetAllUserNames())
ClearItems
Empty the collection
Define
ClearItems()
Example
Empty the collection
VBScript Example
ComboBox0.ClearItems()
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
ComboBox0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
RemoveAtItem
Remove the specified items according to the index
Define
RemoveAtItem(index)
Parameter
Data
Name Required/Optional Description
Type
Remove the
index Required int specified items according to the
index
Example
Remove the first item in the combo box
VBScript Example
ComboBox0.RemoveAtItem(0)
RemoveItem
Remove the specified items
Define
RemoveItem(item)
Parameter
Data
Name Required/Optional Description
Type
item required String Items to be removed
ComboBox0.RemoveItem("a")
BorderBrush
The border color(Colors.Red)
Define
Object BorderBrush
Example
Set the border color of the specified object
VBScript Example
ComboBox0.BorderBrush = Colors.Red
FontSize
Font size
Define
Double FontSize
Example
Set the font size of the specified object
VBScript Example
ComboBox0.FontSize = 20
Foreground
The foreground color(Colors.Red)
Define
Object Foreground
Example
Set the foreground color of the specified object
VBScript Example
ComboBox0.Foreground = Colors.Red
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
ComboBox0.Height = 100
IsEnabled
Gets or sets a value, the value indicating whether the control can
operation
Define
Boolean IsEnabled
Example
True :The specified object is Enabled
VBScript Example
ComboBox0.IsEnabled = True
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
ComboBox0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = ComboBox0.Name
Opacity
Opacity
Define
Double Opacity
Example
The graphics display translucent effect
VBScript Example
ComboBox0.Opacity = 0.5
RotateAngle
Rotation Angle
Define
Double RotateAngle
Example
Set the rotation Angle of the specified object to 90
VBScript Example
ComboBox0.RotateAngle = 90
SelectedIndex
Select the specified item accordding to the index
Define
Int32 SelectedIndex
Example
Select the first item in the combo box
VBScript Example
ComboBox0.SelectedIndex = 0
SelectedValue
Select the current value
Define
String SelectedValue
Example
Select "a" in the combo box as the current value
VBScript Example
ComboBox0.SelectedValue = "a"
Text
Get or the set up the text content of the combo box
Define
String Text
Example
Set the text of the specified object to "Delta SCADA"
VBScript Example
ComboBox0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
ComboBox0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
ComboBox0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example Set the Layer index of the specified object to 3
VBScript Example
ComboBox0.ZIndex = 3
HMILabel
Label control
Methods list
Name Description
Look for animation to modify the
FindAnimation
associated variables of the animation
Property list
Name Description
Background The background color
FontSize Font size
Foreground Foreground
Height Height
Get or set a value, the value indicating
IsEnabled
whether the control can operation
IsShow Whether display the specified object
Left The left coordinate
Name Name
Opacity Opacity
RotateAngle Rotation Angle
Get or the set up the text content of the
Text
label
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object
into Var.VariableGroup0.Variable1
VBScript Example
Label0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
Background
The background color(Colors.Red)
Define
Object Background
Example
Set the background color of the specified object
VBScript Example
Label0.Background = Colors.Red
FontSize
Font size
Define
Double FontSize
Example
Set the font size of the specified object
VBScript Example
Label0.FontSize = 20
Foreground
The foreground color(Colors.Red)
Define
Object Foreground
Example
Set the foreground color of the specified object
VBScript Example
Label0.Foreground = Colors.Red
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
Label0.Height = 100
IsEnabled
Gets or sets a value, the value indicating whether the control can
operation
Define
Boolean IsEnabled
Example
True :The specified object is Enabled
VBScript Example
Label0.IsEnabled = True
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
Label0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = Label0.Name
Opacity
Opacity
Define
Double Opacity
Example
The graphics display translucent effect
VBScript Example
Label0.Opacity = 0.5
RotateAngle
Rotation Angle
Define
Double RotateAngle
Example
Set the rotation Angle of the specified object to 90
VBScript Example
Label0.RotateAngle = 90
Text
Gets or sets up the text content of the label
Define
String Text
Example
Set the text of the specified object to "Delta SCADA"
VBScript Example
Label0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
Label0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
Label0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example Set the Layer index of the specified object to 3
VBScript Example
Label0.ZIndex = 3
HMITextBox
Text box control
Methods list
Name Description
Look for animation to modify the
FindAnimation
associated variables of the animation
Focus Set the focus on the text box
SelectedAll Select all the contents of the text box
Property list
Name Description
Get or set a value, the value indicating
AcceptsReturn
whether the text content wrap
Background The background color
BorderBrush Border color
FontSize Font size
Foreground Foreground
Height Height
Get or set a value, the value indicating
IsEnabled
whether the control can operation
IsShow Whether display the specified object
Left The left coordinate
Name Name
Opacity Opacity
RotateAngle Rotation Angle
Get or the set up the text content of the
Text
text box
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
TextBox0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
Focus
Set the focus on the text box
Define
Focus()
Example Set the focus on the TextBox0
VBScript Example
TextBox0.Focus()
SelectedAll
Select all the contents of the text box
Define
SelectAll()
Example Select all the contents of the text box 0(Note: first, set the
focus on the TextBox0)
VBScript Example
TextBox0.Focus()
TextBox0.SelectAll()
AcceptsReturn
Gets or sets a value, the value indicating whether the text content
wrap
Define
Boolean AcceptsReturn
Example
True: the text content wrap False: the text content will not wrap
VBScript Example
TextBox0.AcceptsReturn = True
TextBox0.AcceptsReturn = False
Background
The background color(Colors.Red)
Define
Object Background
Example
Set the background color of the specified object
VBScript Example
TextBox0.Background = Colors.Red
BorderBrush
The border color(Colors.Red)
Define
Object BorderBrush
Example
Set the border color of the specified object
VBScript Example
TextBox0.BorderBrush = Colors.Red
FontSize
Font size
Define
Double FontSize
Example
Set the font size of the specified object
VBScript Example
TextBox0.FontSize = 20
Foreground
The foreground color(Colors.Red)
Define
Object Foreground
Example
Set the foreground color of the specified object
VBScript Example
TextBox0.Foreground = Colors.Red
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
TextBox0.Height = 100
IsEnabled
Gets or sets a value, the value indicating whether the control can
operation
Define
Boolean IsEnabled
Example
True :The specified object is Enabled
VBScript Example
TextBox0.IsEnabled = True
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
TextBox0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox1.Text = TextBox0.Name
Opacity
Opacity
Define
Double Opacity
Example
Graphical display translucent effect
VBScript Example
TextBox0.Opacity = 0.5
RotateAngle
Rotation Angle
Define
Double RotateAngle
Example
Set the rotation Angle of the specified object to 90
VBScript Example
TextBox0.RotateAngle = 90
Text
Gets or sets up the text content of text box
Define
String Text
Example
Set the text of the specified object to "Delta SCADA"
VBScript Example
TextBox0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
TextBox0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
TextBox0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example Set the Layer index of the specified object to 3
VBScript Example
Text0.ZIndex = 3
HMIPasswordBox
Password box control
Methods list
Name Description
Look for animation to modify the
FindAnimation
associated variables of the animation
Property list
Name Description
Background The background color
BorderBrush The border color
FontSize Font size
Foreground The foreground color
Height Height
Get or set a value, the value indicating
IsEnabled whether the text content carriage
returns
IsShow Whether display the specified object
Left The left coordinate
Name Name
Opacity Opacity
Get or set the password content,
Password
shown as a small dot
RotateAngle Rotation Angle
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
PasswordBox0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
Background
The background color(Colors.Red)
Define
Object Background
Example
Set the background color of the specified object
VBScript Example
PasswordBox0.Background = Colors.Red
BorderBrush
The border color(Colors.Red)
Define
Object BorderBrush
Example
Set the border color of the specified object
VBScript Example
PasswordBox0.BorderBrush = Colors.Red
FontSize
Font size
Define
Double FontSize
Example
Set the font size of the specified object
VBScript Example
PasswordBox0.FontSize = 20
Foreground
The foreground color(Colors.Red)
Define
Object Foreground
Example
Set the foreground color of the specified object
VBScript Example
PasswordBox0.Foreground = Colors.Red
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
PasswordBox0.Height = 100
IsEnabled
Gets or sets a value, the value indicating whether the control can
operation
Define
Boolean IsEnabled
Example
True :The specified object is Enabled
VBScript Example
PasswordBox0.IsEnabled = True
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
PasswordBox0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = PasswordBox0.Name
Opacity
Opacity
Define
Double Opacity
Example
The graphics display translucent effect
VBScript Example
PasswordBox0.Opacity = 0.5
Password
Gets or sets the password content, shown as a small dot
Define
String Password
Example
Set the password content to “123456”
VBScript Example
PasswordBox0.Password = "123456"
RotateAngle
Rotation Angle
Define
Double RotateAngle
Example
Set the rotation Angle of the specified object to 90
VBScript Example
PasswordBox0.RotateAngle = 90
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
PasswordBox0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
PasswordBox0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
PasswordBox0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example Set the Layer index of the specified object to 3
VBScript Example
PasswordBox0.ZIndex = 3
HMIDateTimePicker
Date time picker control
Methods list
Name Description
Compare Date/time to compare
CompareDate Date to compare
CompareTime Time to compare
Look for animation to modify the
FindAnimation
associated variables of the animation
GetTimeValue Get the time value
Property list
Name Description
Background The background color
FontSize Font size
Foreground The foreground color
Height Height
IntervalHours Get hours interval
IntervalMilliseconds Get interval number of milliseconds
IntervalMinutes Get interval number of minutes
IntervalSeconds Get interval number of seconds
Get or set a value, the value
IsEnabled indicating whether the control can
operation
IsShow Whether display the specified object
Left The left coordinate
Name Name
Opacity Opacity
RotateAngle Rotation angle
ToolTip Tooltip text
Top The top coordinate
Get or set the display values of the
Value
calendar date time
Get the display values of the
ValueTime
calendar date time
Width Width
ZIndex Layer index
Compare
Date/Time comparison
Define
Compare(dateTime)
Parameter
Data
Name Required/Optional Description
Type
dateTime Required DateTime DataTime
Return
The return value is greater than 1, the date displayed by control is
greater than the input date; less than zero, less than the input date,
equal to zero is equal to the input date
Example
Call this script, compared the current date with the date displayed by
calendar, if the return value is greater than zero, indicate that the
date displayed by calendar is greater than the input date; equal to
zero, indicate that the date displayed by calendar is equal to the
input date; less than zero, indicate that the date displayed by
calendar is less than the input date.
VBScript Example
DateTimePicker0.Compare(DateTime.Now)
CompareDate
Date/Time comparison
Define
CompareDate(dateTime)
Parameter
Data
Name Required/Optional Description
Type
dateTime Required DateTime Date/Time
Return
The return value is greater than 1, the date displayed by control is
greater than the input date; less than zero, less than the input date,
equal to zero is equal to the input date
Example
Call this script, compared the current date with the date displayed by
calendar, if the return value is greater than zero, indicate that the
date displayed by calendar is greater than the input date; equal to
zero, indicate that the date displayed by calendar is equal to the
input date; less than zero, indicate that the date displayed by
calendar is less than the input date.
VBScript Example
DateTimePicker0.CompareDate(DateTime.Now)
CompareTime
Date/Time comparison
Define
CompareTime(dateTime)
Parameter
Data
Name Required/Optional Description
Type
dateTime Required DateTime Date/Time
Return
The return value is greater than 1, the date displayed by control is
greater than the input date; less than zero, less than the input date,
equal to zero is equal to the input date
Example
Call this script, compared the current date with the time displayed by
calendar, if the return value is greater than zero, indicate that the
time displayed by calendar is greater than the input time; equal to
zero, indicate that the time displayed by calendar is equal to the
input time; less than zero, indicate that the time displayed by
calendar is less than the input time.
VBScript Example
DateTimePicker0.CompareTime(DateTime.Now)
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
DateTimePicker0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
GetTimeValue
Get the time value
Define
GetTimeValue(name)
Parameter
Data
Name Required/Optional Description
Type
name Required String The name of the time
Return
DateTimePicker0.GetTimeValue("M")
Background
The background color(Colors.Red)
Define
Object Background
Example Set the background color of the specified object
VBScript Example
DateTimePicker0.Background = Colors.Red
FontSize
Font size
Define
Double FontSize
Example
Set the font size of the specified object
VBScript Example
DateTimePicker0.FontSize = 20
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
DateTimePicker0.Height = 100
IntervalHours
Get interval hours
Define
Int32 IntervalHours
Example
Get interval hours to display in the text box
VBScript Example
TextBox0.Text = DateTimePicker0.IntervalHours
IntervalMilliseconds
Get interval milliseconds
Define
Int32 IntervalMilliseconds
Example
Get interval milliseconds to display in the text box
VBScript Example
TextBox0.Text =
DateTimePicker0.IntervalMilliseconds
IntervalMinutes
Get interval minutes
Define
Int32 IntervalMinutes
Example
Get interval minutes to display in the text box
VBScript Example
TextBox0.Text = DateTimePicker0.IntervalMinutes
IntervalSeconds
Get interval seconds
Define
Int32 IntervalSeconds
Example
Get interval seconds to display in the text box
VBScript Example
TextBox0.Text = DateTimePicker0.IntervalSeconds
IsEnabled
Gets or sets a value, the value indicating whether the control can
operation
Define
Boolean IsEnabled
Example
True :The specified object is Enabled
VBScript Example
DateTimePicker0.IsEnabled = True
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
DateTimePicker0.IsShow = True
DateTimePicker0.IsShow = False
Left
The left coordinate
Define
Double Left
Example Object's left side of the coordinate values is 100 on the
screen
VBScript Example
DateTimePicker0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = DateTimePicker0.Name
Opacity
Opacity
Define
Double Opacity
Example
The graphics display translucent effect
VBScript Example
DateTimePicker0.Opacity = 0.5
RotateAngle
Rotation Angle
Define
Double RotateAngle
Example
Set the rotation Angle of the specified object to 90
VBScript Example
DateTimePicker0.RotateAngle = 90
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
DateTimePicker0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
DateTimePicker0.Top = 100
Value
Gets or sets values of time of calendar date displayed
Define
DateTime Value
Example
Get values of DataTimePicker0 to display in text box
VBScript Example
TextBox0.Text = DateTimePicker0.Value
ValueTime
Get values of time of calendar date displayed
Define
DateTime ValueTime
Example
Get values of DataTimePicker0 to display in text box
VBScript Example
TextBox0.Text = DateTimePicker0.ValueTime
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
DateTimePicker0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example Set the Layer index of the specified object to 3
VBScript Example
DateTimePicker0.ZIndex = 3
HMIDatePicker
Date control
Methods list
Name Description
CompareDate Comparison the date
Look for animation to modify the
FindAnimation
associated variables of the animation
Property list
Name Description
Background The background color
BorderBrush Border color
FontSize Font size
Foreground The foreground color
Height Height
Get or set a value, the value indicating
IsEnabled
whether the control can operation
IsShow Whether display the specified object
Left The left coordinate
Name Name
Opacity Opacity
RotateAngle Rotation Angle
Get or set the date string of the date
Text
displayed
ToolTip Tooltip text
Top The top coordinate
ValueTime Get the date value of the calendar
Width Width
ZIndex Layer index
CompareDate
Date comparison
Define
CompareDate(dateTime)
Parameter
Data
Name Required/Optional Description
Type
dateTime Required DateTime
Example
Call this script, compared the current date with the date displayed by
calendar, if the return value is greater than zero, indicate that the
date displayed by calendar is greater than the incoming date; equal
to zero, indicate that the date displayed by calendar is equal to the
incoming date; less than zero, indicate that the date displayed by
calendar is less than the incoming date.
VBScript Example
DatePicker0.CompareDate(DateTime.Now)
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
DatePicker0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
Background
The background color(Colors.Red)
Define
Object Background
Example
Set the background color of the specified object
VBScript Example
DatePicker0.Background = Colors.Red
BorderBrush
The border color(Colors.Red)
Define
Object BorderBrush
Example
Set the border color of the specified object
VBScript Example
DatePicker0.BorderBrush = Colors.Red
FontSize
The font size
Define
Double FontSize
Example
Set the font size of the specified object
VBScript Example
DatePicker0.FontSize = 20
Foreground
The foreground color(Colors.Red)
Define
Object Foreground Example
Set the foreground color of the specified object
VBScript Example
DatePicker0.Foreground = Colors.Red
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
DatePicker0.Height = 100
IsEnabled
Gets or sets a value, the value indicating whether the control can
operation
Define
Boolean IsEnabled
Example The specified object is Enabled
VBScript Example
DatePicker0.IsEnabled = True
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
DatePicker0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = DatePicker0.Name
Opacity
Opacity
Define
Double Opacity
Example
The graphics display translucent effect
VBScript Example
DatePicker0.Opacity = 0.5
RotateAngle
Rotation Angle
Define
Double RotateAngle
Example
Set the rotation Angle of the specified object to 90
VBScript Example
DatePicker0.RotateAngle = 90
Text
Gets or sets up the string of the date displayed
Define
String Text
Example
VBScript Example
DatePicker0.Text = "2014/8/9"
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
DatePicker0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
DatePicker0.Top = 100
ValueTime
Get values of calendar date displayed
Define
DateTime ValueTime
Example
VBScript Example
TextBox0.Text = DatePicker0.ValueTime
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
DatePicker0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example Set the Layer index of the specified object to 3
VBScript Example
DatePicker0.ZIndex = 3
HMICalendar
Calendar control
Methods list
Name Description
Look for animation to modify the
FindAnimation
associated variables of the animation
Property list
Name Description
Background The background color
BorderBrush The border color
Foreground The foreground color
Get or set a value, the value indicating
IsEnabled
whether the control can operation
IsShow Whether display the specified object
Left The left coordinate
Name Name
Opacity Opacity
ToolTip Tooltip text
Top The top coordinate
ZIndex Layer index
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
Calendar0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
Background
The background color(Colors.Red)
Define
Object Background
Example
Set the background color of the specified object
VBScript Example
Calendar0.Background = Colors.Red
BorderBrush
The border color(Colors.Red)
Define
Object BorderBrush
Example
Set the border color of the specified object
VBScript Example
Calendar0.BorderBrush = Colors.Red
Foreground
The foreground color(Colors.Red)
Define
Object Foreground
Example
Set the foreground color of the specified object
VBScript Example
Calendar0.Foreground = Colors.Red
IsEnabled
Gets or sets a value, the value indicating whether the control can
operation
Define
Boolean IsEnabled
Example The specified object is Enabled
VBScript Example
Calendar0.IsEnabled = True
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
Calendar0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = Calendar0.Name
Opacity
Opacity
Define
Double Opacity
Example
The graphics display translucent effect
VBScript Example
Calendar0.Opacity = 0.5
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
Calendar0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
Calendar0.Top = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example Set the Layer index of the specified object to 3
VBScript Example
Calendar0.ZIndex = 3
HMIImage
Image control
Methods list
Name Description
Look for animation to modify the
FindAnimation
associated variables of the animation
Property list
Name Description
Height Height
IsShow Whether display the specified object
Left The left coordinate
Name Name
Opacity Opacity
RotateAngle Rotation angle
SwitchingPath Switch the image path
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object
into Var.VariableGroup0.Variable1
VBScript Example
Image0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
Image0.Height = 100
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
Image0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = Image0.Name
Opacity
Opacity
Define
Double Opacity
Example
The graphics displays translucent effect
VBScript Example
Image0.Opacity = 0.5
RotateAngle
Rotation Angle
Define
Double RotateAngle
Example
Set the rotation Angle of the specified object to 90
VBScript Example
Image0.RotateAngle = 90
SwitchingPath
Switch the image path
Define
String SwitchingPath
Example Switch the image path, test.jpg must exist under the
Image of the project file
VBScript Example
Image0.SwitchingPath = "C:\test.jpg"
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
Image0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
Image0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
Image0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example Set the Layer index of the specified object to 3
VBScript Example
Image0.ZIndex = 3
HMIGIFImage
GIF image control
Methods list
Name Description
Look for animation to modify the
FindAnimation
associated variables of the animation
StartAnimate Start animation
StopAnimate Stop animation
Property list
Name Description
Height Height
IsEnabled whether can operation
IsShow Whether display the specified object
Left The left coordinate
Name Name
Opacity Opacity
RotateAngle Rotation angle
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
GIFImage0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
StartAnimate
Start animation
Define
StartAnimate()
Example
Execute the script will start animation of GIF images
VBScript Example
Call GIFImage0.StartAnimate()
StopAnimate
Stop animation
Define
StopAnimate()
Example
Execute the script will stop animation of GIF images
VBScript Example
Call GIFImage0.StopAnimate()
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
GIFImage0.Height = 100
IsEnabled
Gets or sets a value, the value indicating whether the control can
operation
Define
Boolean IsEnabled
Example The specified object is Enabled
VBScript Example
GIFImage0.IsEnabled = True
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
GIFImage0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = GIFImage0.Name
Opacity
Opacity
Define
Double Opacity
Example
The graphics displays translucent effect
VBScript Example
GIFImage0.Opacity = 0.5
RotateAngle
Rotation Angle
Define
Double RotateAngle
Example
Set the rotation Angle of the specified object to 90
VBScript Example
GIFImage0.RotateAngle = 90
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
GIFImage0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
GIFImage0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
GIFImage0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example Set the Layer index of the specified object to 3
VBScript Example
GIFImage0.ZIndex = 3
HMINixieTube
Nixie tube control
Methods list
Name Description
Look for animation to modify the
FindAnimation
associated variables of the animation
Property list
Name Description
Background The background color
Bit Digital tube integer number
Get or set a value, the value indicating
IsEnabled
whether the control can operation
IsShow Whether display the specified object
Left The left coordinate
Name Name
Number The numeric value displayed
Opacity Opacity
RotateAngle Rotation angle
ToolTip Tooltip text
Top The top coordinate
ZIndex Layer index
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
NixieTube0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
Background
The background color(Colors.Red)
Define
Object Background
Example
Set the background color of the specified object
VBScript Example
NixieTube0.Background = Colors.Red
Bit
Digital tube's integer number
Define
int Bit
Example
Set the integer number to 3
VBScript Example
NixieTube0.Bit = 3
IsEnabled
Gets or sets a value, the value indicating whether the control can
operation
Define
Boolean IsEnabled
Example The specified object is Enabled
VBScript Example
NixieTube0.IsEnabled = True
IsShow
Whether display the specified object
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
NixieTube0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = NixieTube0.Name
Number
The number displayed by Digital tube
Define
double Number
Example
Set the number of the specified object to 1.23
VBScript Example
NixieTube0.Number = 1.23
Opacity
Opacity
Define
Double Opacity
Example
The graphics display translucent effect
VBScript Example
NixieTube0.Opacity = 0.5
RotateAngle
Rotation Angle
Define
Double RotateAngle
Example
Sets the rotation Angle of the specified object to 90
VBScript Example
NixieTube0.RotateAngle = 90
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
NixieTube0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example
Objects in the picture on the top of the y coordinate value is 100
VBScript Example
NixieTube0.Top = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example Set the Layer index of the specified object to 3
VBScript Example
NixieTube0.ZIndex = 3
HMICurvedRuler
Curved ruler control
Methods list
Name Description
Look for animation to modify the
FindAnimation
associated variables of the animation
Property list
Name Description
BigTickNumber The number of big tick
EndOffset The end value of the ruler
IsArcVisible Whether display the arc or not
Get or set a value, the value indicating
IsEnabled
whether the control can operation
Whether display the specified object or
IsShow
not
IsTextVisible Whether display the text or not
Left The left coordinate
LineBrush The current color of the ruler
Name Name
Opacity Opacity
RotateAngle Rotation angle
ScanAngle Scan angle
SmallTickNumber The number of small tick
StartAngle Start angle
StartOffset The start value of the ruler
TickHeight Height
ToolTip Tooltip text
Top The top coordinate
ZIndex Layer index
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
CurvedRuler0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
BigTickNumber
Gets or sets the number of big scales on the CurvedRuler
Define
Int BigTickNumber
Example Set the number of the big scale to 10
VBScript Example
CurvedRuler0.BigTickNumber = 10
EndOffset
Gets or sets the end value of the CurvedRuler
Define
Double EndOffset
Example Set the end value of the ruler to 110
VBScript Example
CurvedRuler0.EndOffset = 110
IsArcVisible
Whether display the arc or not
Define
Boolean IsArcVisible
Example True:display the arc False:hidden the arc
VBScript Example
CurvedRuler0..IsArcVisible = True
CurvedRuler0..IsArcVisible = False
IsEnabled
Get or set a value, the value indicating whether the control can
operation
Define
Boolean IsEnabled
Example The specified object is Enabled
VBScript Example
CurvedRuler0.IsEnabled = True
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
CurvedRuler0.IsTextVisible = True
CurvedRuler0.IsTextVisible = False
Left
The left coordinate
Define
Double Left
Example Object's left side of the coordinate values is 100 on the
screen
VBScript Example
CurvedRuler0.Left = 100
LineBrush
Gets or sets the current color of ruler(Colors.red)
Define
Object LineBrush
Example
Set the current color of the specified object
VBScript Example
CurvedRuler0.LineBrush = Colors.red
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = CurvedRuler0.Name
Opacity
Opacity
Define
Double Opacity
Example
The graphics display translucent effect
VBScript Example
CurvedRuler0.Opacity = 0.5
RotateAngle
Rotation Angle
Define
Double RotateAngle
Example
Sets the rotation Angle of the specified object to 90
VBScript Example
CurvedRuler0.RotateAngle = 90
ScanAngle
Gets or sets the scanning angle of the scale
Define
Double ScanAngle
Example
Sets the scan Angle of the specified object to 180
VBScript Example
CurvedRuler0.ScanAngle = 180
SmallTickNumber
Gets or sets the number of small scales on the CurvedRuler
Define
Int SmallTickNumber
Example Set the number of the small scale to 5
VBScript Example
CurvedRuler0.SmallTickNumber = 5
StartAngle
Start angle
Define
Double StartAngle
Example
The Start Angle value is 90 of the circular arc
VBScript Example
CurvedRuler0.StartAngle = 90
StartOffset
Gets or sets the start value of the CurvedRuler
Define
Double StartOffset
Example Set the start value of the ruler to 10
VBScript Example
CurvedRuler0.StartOffset = 10
TickHeight
Gets or sets the height of the scale
Define
Double TickHeight
Example Set the height of the scale to 10
VBScript Example
CurvedRuler0.TickHeight = 10
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
CurvedRuler0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
CurvedRuler0.Top = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example Set the Layer index of the specified object to 3
VBScript Example
CurvedRuler0.ZIndex = 3
HMITable
Table control
Methods list
Name Description
Look for animation to modify the
FindAnimation
associated variables of the animation
Property list
Name Description
DataBackground Set data background color
Set first column background
FirstColumnBackground
color
FirstRowBackground Set first row background color
Height Height
Whether to display the specified
IsShow
object
Whether display the oblique line
IsShowObliqueLine
in the upper left corner
Whether to enable row cross
IsShowRowCross
display
Left The left coordinate
Name Name
Opacity Opacity
RotateAngle Rotation Angle
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object
into Var.VariableGroup0.Variable1
VBScript Example
Table0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
DataBackground
Set data background color(Colors.Red),it only works when the row
cross display property is invalid.
Define
Object DataBackground
Example Set data background color
VBScript Example
Table0.DataBackground = Colors.Red
FirstColumnBackground
Set first column background color(Colors.Red), it only works when
the oblique line in the upper left corner is display
Define
Object FirstColumnBackground
Example Set first column background color
VBScript Example
Table0.FirstColumnBackground = Colors.Red
FirstRowBackground
Set first row background color(Colors.Red)
Define
Object FirstRowBackground
Example Set first row background color
VBScript Example
Table0.FirstRowBackground = Colors.Red
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
Table0.Height = 100
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
Table0.IsShowObliqueLine = True
Table0.IsShowObliqueLine = False
IsShowRowCross
Set whether to enable the row cross display
Define
Boolean IsShowRowCross
Example True :Enable the property of row cross display False :
Unable the property of row cross display
VBScript Example
Table0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = Table0.Name
Opacity
Opacity
Define
Double Opacity
Example
The graphics displays translucent effect
VBScript Example
Table0.Opacity = 0.5
RotateAngle
Rotation Angle
Define
Double RotateAngle
Example
Set the rotation Angle of the specified object to 90
VBScript Example
Table0.RotateAngle = 90
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
Table0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
Table0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
Table0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example Set the Layer index of the specified object to 3
VBScript Example
Table0.ZIndex = 3
HMIUniBarcode
UniBarcode control
Methods list
Name Description
Look for animation to modify the
FindAnimation
associated variables of the animation
Save Save as picture
Save Save as picture
Property list
Name Description
Background The background color
Height Height
Get or set a value, the value indicating
IsEnabled
whether the control can operation
IsShow Whether display the specified object
Left The left coordinate
Name Name
Opacity Opacity
RotateAngle Rotation Angle
Get or the set up the text content of the
Text
barcode
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
UniBarcode0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
Save
Save
Define
Save()
Example
Save
VBScript Example
Call UniBarcode0.Save()
Save
Save as pictures
Define
Save(name)
Parameter
Data
Name Required/Optional Description
Type
The absolute path where the
name Required String
picture is saved
Example
Save
VBScript Example
Call UniBarcode0.Save("D:\UniBarcode.jpg")
Background
The background color(Colors.Red)
Define
Object Background
Example
Set the background color of the specified object
VBScript Example
UniBarcode0.Background = Colors.Red
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
UniBarcode0.Height = 100
IsEnabled
Gets or sets a value, the value indicating whether the control can
operation
Define
Boolean IsEnabled
Example
True :The specified object is Enabled
VBScript Example
UniBarcode0.IsEnabled = True
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
UniBarcode0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = UniBarcode0.Name
Opacity
Opacity
Define
Double Opacity
Example
Graphical display translucent effect
VBScript Example
UniBarcode0.Opacity = 0.5
RotateAngle
Rotation Angle
Define
Double RotateAngle
Example
Set the rotation Angle of the specified object to 90
VBScript Example
UniBarcode0.RotateAngle = 90
Text
Gets or sets up the text content of the barcode
Define
String Text
Example
Set the text of the specified object to "01234567"
VBScript Example
UniBarcode0.Text = "01234567"
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
UniBarcode0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
UniBarcode0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
UniBarcode0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example Set the Layer index of the specified object to 3
VBScript Example
UniBarcode0.ZIndex = 3
HMIQRCode
QRCode control
Methods list
Name Description
Look for animation to modify the
FindAnimation
associated variables of the animation
Save Save as picture
Save Save as picture
Property list
Name Description
Background The background color
Height Height
Get or set a value, the value indicating
IsEnabled
whether the control can operation
IsShow Whether display the specified object
Left The left coordinate
Name Name
Opacity Opacity
RotateAngle Rotation Angle
Get or the set up the text content of the
Text
QR code
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
QRCode0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
Save
Save
Define
Save()
Example
Save
VBScript Example
Call QRCode0.Save()
Save
Save as pictures
Define
Save(name)
Parameter
Data
Name Required/Optional Description
Type
The absolute path where the
name Required String
picture is saved
Example
Save
VBScript Example
Call QRCode0.Save("D:\UniBarcode.jpg")
Background
The background color(Colors.Red)
Define
Object Background
Example
Set the background color of the specified object
VBScript Example
QRCode0.Background = Colors.Red
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
QRCode0.Height = 100
IsEnabled
Gets or sets a value, the value indicating whether the control can
operation
Define
Boolean IsEnabled
Example
True :The specified object is Enabled
VBScript Example
QRCode0.IsEnabled = True
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
QRCode0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = QRCode0.Name
Opacity
Opacity
Define
Double Opacity
Example
Graphical display translucent effect
VBScript Example
QRCode0.Opacity = 0.5
RotateAngle
Rotation Angle
Define
Double RotateAngle
Example
Set the rotation Angle of the specified object to 90
VBScript Example
QRCode0.RotateAngle = 90
Text
Gets or sets up the text content of the QRCode.Does not support
Chinese characters
Define
String Text
Example
Set the text of the specified object to "DIAView test123"
VBScript Example
QRCode0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
QRCode0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
QRCode0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example Set the Layer index of the specified object to 3
VBScript Example
QRCode0.ZIndex = 3
HMIRealTimeChart
Real time chart control
Methods list
Name Description
AddNewLimitLine Add a new limit line
Image array translate into
ArrayToString
string
DeletevalueAll Delete all data points
Export Export data
ExportRealData Export excel
Look for animation to modify
FindAnimation the associated variables of
the animation
HiddenSeries Hidden curve
Get saved path selected by
OpenShowFileDialog
dialog box
Print Print
RemoveAllLimitLine Remove all the limit line
Save Save
Save Save as pictures
Curve correlation variable
SetSeriesVariablePath
substitution
Set the time interval and
SetTimeRangeWithRefresh
refresh interval
StartTimer Start timer
StopTimer Stop timer
VisiableSeries Display curves
Property list
Name Description
Height Height
IsShow Whether display specified object
Whether display the positioning
IsShowBtnCrossLine
line button
IsShowBtnLeftMost Whether display the most left
button
Whether display the left shift
IsShowBtnLeftShift
button
IsShowBtnReSet Whether display the reset button
Whether display the most right
IsShowBtnRightMost
button
Whether display the right shift
IsShowBtnRigthShift
button
Whether display the curve
IsShowRealBtnConfig
configuration button
IsShowRealBtnPrint Whether display the print button
IsShowRealBtnSave Whether display the save button
Whether display the began or
IsShowRealBtnStop
pause button
Whether display the pause time
IsShowStopTime
button
Left The left coordinate
Name Name
Get or set the maximum scale of
NumberInterval
numerical axis
Get or set the minimum scale of
NumberSmallInterval
numerical axis
Get or set the maximum scale of
NumericalAxisMaximum
numerical axis
Get or set the minimum scale of
NumericalAxisMinimum
numerical axis
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
AddNewLimitLine
Add new limit line (The "UpperAndLowerDisplay" is checked in the control
property)
Define
AddNewLimitLine(variablePath ,defaultValue ,color , thickness)
Parameter
Name Required/Optional Data Type Description
variablePath Required String Variable path
defaultValue Required Double Default value (default)
color Required Brush Line fill color
thickness Required Double Line thicknesses
Example
VBScript Example
Call
RealtimeChart0.AddNewLimitLine("Var.Variable",0,Colors.Red,5)
ArrayToString
Image array translate into string
Define
ArrayToString(seriesName)
Parameter
1. The two diferent curve pictures from two different realtimechart are exported to the same report
("D:\Test.xlsx"is the save path of Excel,"report0"is the report
template,"RealtimeChart0.ArrayToString("Series0")" is the pictures set)
VBScript Example
Call
ReportCmd.ExportDataByTemplate("D:\Test.xlsx","Report0",RealtimeChart0.ArrayTo
2. The two diferent curve pictures from one realtimechart are exported to the same report
VBScript Example
Call
ReportCmd.ExportDataByTemplate("D:\Test.xlsx","Report0",RealtimeChart0.ArrayTo
DeletevalueAll
Delete all data points
Define
DeletevalueAll()
Example
Delete all data points
VBScript Example
Call RealtimeChart0.DeletevalueAll()
Export
Export data
Define
Export(seriesName ,templateName)
Parameter
Data
Name Required/Optional Description
Type
Name of the
seriesName Required String
curve
templateName Required String Report template
Example
Export a curve image into the report
VBScript Example
Call
RealtimeChart0.Export("Series0;Series1","Report0")
ExportRealData
Export excel
Define
ExportRealData(seriesName)
Parameter
Name Required/Optional Data Type Description
seriesName Required String Name of the curve
Example
Export excel
VBScript Example
Call RealtimeChart0.ExportRealData("Series0")
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
RealtimeChart0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
HiddenSeries
Hide the curve
Define
HiddenSeries(seriesName)
Parameter
Data
Name Required/Optional Description
Type
Name of the curve,
seriesName Required String
separate by commas
Example
Hide the curve
VBScript Example
Call RealtimeChart0.HiddenSeries("Series0")
OpenShowFileDialog
Get saved path which selected by dialog box
Define
OpenShowFileDialog()
Example
Get saved path which selected by dialog box
VBScript Example
tt = RealtimeChart0.OpenShowFileDialog()
Call
ReportCmd.ExportDataByTemplate(tt,"Report0",RealtimeChart0.ArrayToString("Seri
Print
Print
Define
Print()
Example
Print
VBScript Example
Call RealtimeChart0.Print()
RemoveAllLimitLine
Remove all the limit line
Define
RemoveAllLimitLine()
Example
Remove all the limit line
VBScript Example
Call RealtimeChart0.RemoveAllLimitLine()
Save
Save
Define
Save()
Example
Save
VBScript Example
Call RealtimeChart0.save()
Save
Save as pictures
Define
Save(path , seriesName)
Parameter
Data
Name Required/Optional Description
Type
path Required String An absolute path
Name of curve,
seriesName Required String
separate by commas
Example
Save
VBScript Example
Call RealtimeChart0.save("D:\test.jpg","Series0")
SetSeriesVariablePath
Curve correlation variable substitution
Define
SetSeriesVariablePath(pathList)
Parameter
Data
Name Required/Optional Description
Type
The new variable path of the variables that replace the
pathList Required String
old variables , separate by commas
Example
Curve correlation variable substitution
VBScript Example
Call RealtimeChart0.SetSeriesVariablePath("Var.variable0,Var.variable1")
SetTimeRangeWithRefresh
Set the time interval and refresh time
Define
SetTimeRangeWithRefresh(rangeH ,rangeM ,rangeS ,refreshH ,
refreshM ,refreshS)
Parameter
Name Required/Optional Data Type Description
rangeH Required Int Time interval,hour
rangeM Required Int Time interval,minute
rangeS Required Int Time interval,second
refreshH Required Int Refresh,hour
refreshM Required Int Refresh,minute
refreshS Required Int Refresh,second
Example
Set the time interval and refresh time
VBScript Example
Call
RealtimeChart0.SetTimeRangeWithRefresh(0,0,1,0,0,1)
StartTimer
Start timer
Define
StartTimer()
Example
Start Timer
VBScript Example
Call RealtimeChart0.StartTimer()
StopTimer
Stop timer
Define
StopTimer()
Example
Stop Timer
VBScript Example
Call RealtimeChart0.StopTimer()
VisiableSeries
Display the curve
Define
VisiableSeries(seriesName)
Parameter
Data
Name Required/Optional Description
Type
Name of the curve,
seriesName Required String
separate by commas
Example
Display the curve
VBScript Example
Call RealtimeChart0.VisiableSeries("Series0")
SetPageRange
Sets the initial page range value
Defination
SetPageRange(index)
Parameter
Name required/Optional Datatype Description
Sets the initial page range
index required int
value
Example
Sets the initial page range value
VBScript Example
Call
realtimechart0.SetPageRange(Var.realtime0.index)
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
RealtimeChart0.Height = 100
IsShow
Whether display the specified object
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
RealtimeChart0.IsShow = True
RealtimeChart0.IsShow = False
IsShowBtnCrossLine
Whether display the positioning line button
Define
Boolean IsShowBtnCrossLine
Example
Display the positioning line
VBScript Example
RealtimeChart0.IsShowBtnCrossLine = True
IsShowBtnLeftMost
Whether display the most left button
Define
Boolean IsShowBtnLeftMost
Example
Display the most left button
VBScript Example
RealtimeChart0.IsShowBtnLeftMost = True
IsShowBtnLeftShift
Whether display the left shift button
Define
Boolean IsShowBtnLeftShift
Example
Display moves to the left button
VBScript Example
RealtimeChart0.IsShowBtnLeftShift = True
IsShowBtnReSet
Whether display the reset button
Define
Boolean IsShowBtnReSet
Example
Display the reset button
VBScript Example
RealtimeChart0.IsShowBtnReSet = True
IsShowBtnRightMost
Whether display the most right button
Define
Boolean IsShowBtnRightMost
Example
Display the most right button
VBScript Example
RealtimeChart0.IsShowBtnRightMost = True
IsShowBtnShiftRigthShift
Whether display the right shift button
Define
Boolean IsShowBtnRigthShift
Example
Display button to the right
VBScript Example
RealtimeChart0.IsShowBtnRigthShift = True
IsShowRealBtnConfig
Whether display the curve configuration button
Define
Boolean IsShowRealBtnConfig
Example
Display curve configuration button
VBScript Example
RealtimeChart0.IsShowRealBtnConfig = True
IsShowRealBtnPrint
Whether display the print button
Define
Boolean IsShowRealBtnPrint
Example
Display print button
VBScript Example
RealtimeChart0.IsShowRealBtnPrint = True
IsShowRealBtnSave
Whether display the save button
Define
Boolean IsShowRealBtnSave
Example
Display the save button
VBScript Example
RealtimeChart0.IsShowRealBtnSave = True
IsShowRealBtnStop
Whether display the begin or pause button
Define
Boolean IsShowRealBtnStop
Example
Display the begin or pause button
VBScript Example
RealtimeChart0.IsShowRealBtnStop = True
IsShowStopTime
Whether display the pause time button
Define
Boolean IsShowStopTime
Example
Display the pause time button
VBScript Example
RealtimeChart0.IsShowStopTime = True
Left
The left coordinate
Define
Double Left
Example Object's left side of the coordinate values is 100 on the
screen
VBScript Example
RealtimeChart0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = RealtimeChart0.Name
NumberInterval
Get or set the maximum scale of numerical axis
Define
Double NumberInterval
Example
Set the maximum scale of numerical axis to 20
VBScript Example
RealTimeChart0.NumberInterval = 20
NumberSmallInterval
Get or set the minimum scale of numerical axis
Define
Double NumberSmallInterval
Example
Set the minimum scale of numerical axis to 20
VBScript Example
RealTimeChart0.NumberSmallInterval = 4
NumericalAxisMaximum
Get or set the numerical axis maximum
Define
Double NumericalAxisMaximum
Example
Set the numerical axis maximum to 120
VBScript Example
RealTimeChart0.NumberAxisMaximum = 120
NumericalAxisMinimum
Get or set the numerical axis minimum
Define
Double NumericalAxisMinimum
Example
Set the numerical axis minimum to 20
VBScript Example
RealTimeChart0.NumberAxisMinumum = 20
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
RealtimeChart0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
RealtimeChart0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
RealtimeChart0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example
Set the Zindex of the specified object to 3
VBScript Example
RealtimeChart0.ZIndex = 3
HMIHistoryChart
History chart control
Methods list
Name Description
AddNewLimitLine Add new limit line
ArrayToString Image array translate into string
Export Export data
Export Export excel
Look for animation to modify
FindAnimation the associated variables of the
animation
FirstAction The most left
GetDataTable Store data to data table
HiddenSeries Hidden curve
Import Import excel
LastAction The most right
NextAction Right shift
Get the path of save dialog
OpenShowFileDialog
select
PreAction Left shift
Print Print
Set the end time of the query
QueryEndTime
data
QueryHistoryDate Query of the historical data
Query of the historical data(with
QueryHistoryDate
parameters)
QueryInveral Set the query interval
Set the start time of the query
QueryStartTime
data
QueryUnit Set the query unit
RemoveAllLimitLine Remove all the limit line
Save Save
Save Save as pictures
SetSeriesVariablePath Curve correlation variable
substitution
SetVarRecordRulerName Set the name of query rule
VisiableSeries Display curve
Property list
Name Description
Height Height
Whether display the specified
IsShow
object
Whether display the curve
IsShowBtnConfig
configuration button
Whether display the positioning
IsShowBtnCrossLine
line
Whether display the import and
IsShowBtnMenu
export button
IsShowBtnPrint Whether display the print button
IsShowBtnSave Whether display the save button
IsShowBtnUpdate Whether display the query button
Whether display the quick time
IsShowCbTime
setting button
Whether display the time setting
IsShowSetTime
button
IsShowStatusBar Whether display the status column
IsShowToolBar Whether display the tools column
Left The left coordinate
Name Name
Get or set the maximum value of
NumberAxisMaximum
numerical axis
Get or set the minimum value of
NumberAxisMinimum
numerical axis
Get or set the maximum scale of
NumberInterval
numerical axis
Get or set the minimum scale of
NumberSmallInterval
numerical axis
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
AddNewLimitLine
Add new limit line (The "UpperAndLowerDisplay" is checked in the control
property)
Define
AddNewLimitLine(variablePath ,defaultValue ,color , thickness)
Parameter
Name Required/Optional Data Type Description
variablePath Required String Variable path
defaultValue Required Double Default value (default)
color Required Brush Line fill color
thickness Required Double Line thicknesses
Example
VBScript Example
Call
HistoryChart0.AddNewLimitLine("Var.variable",0,Colors.Red,5)
ArrayToString
Image array translate into string
Define
ArrayToString(seriesName)
Parameter
Call HistoryChart0.Export("","Series0;Series1","Report0")
Call
HistoryChart0.Export("D:\Test1.xlsx","Series0;Series1","Report0")
Export
Export excel
Define
Export(seriesName)
Parameter
Name Required/Optional Data Type Description
seriesName Required String Name of the curve
Example
Export curve image into excel
VBScript Example
Call HistoryChart0.Export("Series0")
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
HistoryChart0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
FirstAction
The most left
Define
FirstAction()
Example
The most left
VBScript Example
Call HistoryChart0.FirstAction()
GetDataTable
Store data to data table
Define
GetDataTable(seriesName)
Parameter
VBScript Example
Example
Hide curve
VBScript Example
Call HistoryChart0.HiddenSeries("Series0")
Import
Import excel
Define
Import(seriesName)
Parameter
Data
Name Required/Optional Description
Type
The name of
seriesName Required String
import curve
Example
Import excel
VBScript Example
Call HistoryChart0.Import("Series0")
LastAction
The most right
Define
LastAction()
Example
The most right
VBScript Example
Call HistoryChart0.LastAction()
NextAction
Right shift
Define
NextAction()
Example
Right shift
VBScript Example
Call HistoryChart0.NextAction()
OpenShowFileDialog
Get saved path which selected by dialog box
Define
OpenShowFileDialog()
Example
Get saved path which selected by dialog box
VBScript Example
tt = HistoryChart0.OpenShowFileDialog()
Call
ReportCmd.ExportDataByTemplate(tt,"Report0",HistoryChart0.ArrayToString("Serie
PreAction
Left shift
Define
PreAction()
Example
Left shift
VBScript Example
Call HistoryChart0.PreAction()
Print
Print
Define
Print()
Example
Print
VBScript Example
Call HistoryChart0.Print()
QueryEndTime
Set the end time of the query data
Define
QueryEndTime(dt)
Parameter
Name Required/Optional Data Type Description
dt Required DateTime End time
Example
Set the end time of the query data
VBScript Example
Call
HistoryChart0.QueryStartTime(DateTimePicker0.ValueTime)
Call
HistoryChart0.QueryEndTime(DateTimePicker1.ValueTime)
Call HistoryChart0.QueryInveral(1)
Call HistoryChart0.QueryUnit(0)
Call HistoryChart0.QueryHistoryDate()
QueryHistoryDate
Query of the historical data
Define
QueryHistoryDate()
Example
1.Query the historical data(Timing record)
VBScript Example
Call
HistoryChart0.QueryStartTime(DateTimePicker0.ValueTime)
Call
HistoryChart0.QueryEndTime(DateTimePicker1.ValueTime)
Call HistoryChart0.SetVarRecordRulerName("s1")
Call HistoryChart0.QueryHistoryDate()
Call
HistoryChart0.QueryStartTime(DateTimePicker0.ValueTime)
Call
HistoryChart0.QueryEndTime(DateTimePicker1.ValueTime)
Call HistoryChart0.QueryHistoryDate()
Call
HistoryChart0.QueryStartTime(DateTimePicker0.ValueTime)
Call
HistoryChart0.QueryEndTime(DateTimePicker1.ValueTime)
Call HistoryChart0.QueryInveral(1)
Call HistoryChart0.QueryUnit(0)
Call HistoryChart0.QueryHistoryDate()
QueryHistoryDate
Query of the historical data
Define
QueryHistoryDate(startTime , endTime , inveralTime , index)
Parameter
Data
Name Required/Optional Description
Type
startTime Required DateTime Start time
endTime Required DateTime End time
inveralTime Required Int Time interval
Time interval unit(Value of 0-5,Corresponding to s、
index Required Int
mi、h、d、m、y)
Example
1.Query the historical data(Timing record)
VBScript Example
2.Query the historical data(Change record) or Query the historical group data
VBScript Example
Call
HistoryChart0.QueryHistoryDate(DateTimePicker0.ValueTime,DateTimePicker1.Value
QueryInveral
Set the query interval
Define
QueryInveral(inveral)
Parameter
Name Required/Optional Data Type Description
inveral Required Int Interval
Example
Query the historical group data
VBScript Example
Call
HistoryChart0.QueryStartTime(DateTimePicker0.ValueTime)
Call
HistoryChart0.QueryEndTime(DateTimePicker1.ValueTime)
Call HistoryChart0.QueryInveral(1)
Call HistoryChart0.QueryUnit(0)
Call HistoryChart0.QueryHistoryDate()
QueryStartTime
Set the start time of the query data
Define
QueryStartTime(dt)
Parameter
Name Required/Optional Data Type Description
dt Required DateTime Start time
Example
Query the historical group data
VBScript Example
Call
HistoryChart0.QueryStartTime(DateTimePicker0.ValueTime)
Call
HistoryChart0.QueryEndTime(DateTimePicker1.ValueTime)
Call HistoryChart0.QueryInveral(1)
Call HistoryChart0.QueryUnit(0)
Call HistoryChart0.QueryHistoryDate()
QueryUnit
Set the query unit
Define
QueryUnit(index)
Parameter
Data
Name Required/Optional Description
Type
Time interval unit(Value of 0-5,
index Required Int
Corresponding to s、mi、h、d、m、y)
Example
VBScript Example
Call
HistoryChart0.QueryStartTime(DateTimePicker0.ValueTime)
Call
HistoryChart0.QueryEndTime(DateTimePicker1.ValueTime)
Call HistoryChart0.QueryInveral(1)
Call HistoryChart0.QueryUnit(0)
Call HistoryChart0.QueryHistoryDate()
RemoveAllLimitLine
Remove all limit line
Define
RemoveAllLimitLine()
Example
Remove all limit line
VBScript Example
Call HistoryChart0.RemoveAllLimitLine()
Save
Save
Define
Save()
Example
Save
VBScript Example
Call HistoryChart0.Save()
Save
Save as pictures
Define
Save(path , seriesName)
Parameter
Data
Name Required/Optional Description
Type
path Required String Absolute path
Name of curve,
seriesName Required String
separate by commas
Example
Save
VBScript Example
CallHistoryChart0.Save("D:\test.jpg","Series0")
SetSeriesVariablePath
Curve correlation variable substitution
Define
SetSeriesVariablePath(pathList)
Parameter
Data
Name Required/Optional Description
Type
The new variable path of the variables that replace the
pathList Required String
old variables , separate by commas
Example
Curve correlation variable substitution
VBScript Example
Call HistoryChart0.SetSeriesVariablePath("Var.variable0,Var.variable1")
SetVarRecordRulerName
Set the name of query rule
Define
SetVarRecordRulerName(RuleName)
Parameter
Name Required/Optional Data Type Description
RuleName Required String The name of timer
Example
Set the name of query rule,s1 is the timer name
VBScript Example
Call HistoryChart0.SetVarRecordRulerName("s1")
VisiableSeries
Display the curve
Define
VisiableSeries(seriesName)
Parameter
Data
Name Required/Optional Description
Type
Name of curve,
seriesName Required String
separate by commas
Example
Display the curve
VBScript Example
Call HistoryChart0.VisiableSeries("Series0")
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
HistoryChart0.Height = 100
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
HistoryChart0.IsShowBtnConfig = True
IsShowBtnCrossLine
Whether display the positioning line button
Define
Boolean IsShowBtnCrossLine
Example
Display the positioning line
VBScript Example
HistoryChart0.IsShowBtnCrossLine = True
IsShowBtnMenu
Whether display the import or export button
Define
Boolean IsShowBtnMenu
Example
Display of import or export button
VBScript Example
HistoryChart0.IsShowBtnXYMenu = True
IsShowBtnPrint
Whether display the print button
Define
Boolean IsShowBtnPrint
Example
Display of print button
VBScript Example
HistoryChart0.IsShowBtnPrint = True
IsShowBtnSave
Whether display the save button
Define
Boolean IsShowBtnSave
Example
Display of save button
VBScript Example
HistoryChart0.IsShowBtnSave = True
IsShowBtnUpdate
Whether display the query button
Define
Boolean IsShowBtnUpdate
Example
Display of query button
VBScript Example
HistoryChart0.IsShowBtnUpdate = True
IsShowCbTime
Whether display the quick time setting button
Define
Boolean IsShowCbTime
Example
Display of quick time setting button
VBScript Example
HistoryChart0.IsShowCbTime = True
IsShowSetTime
Whether display the time setting button
Define
Boolean IsShowSetTime
Example
Display of time setting button
VBScript Example
HistoryChart0.IsShowSetTime = True
IsShowStatusBar
Whether display the the status column
Define
Boolean IsShowStatusBar
Example
Whether to display the status column
VBScript Example
HistoryChart0.IsShowStatusBar = True
IsShowToolBar
Whether display the tools column
Define
Boolean IsShowToolBar
Example
Whether display the tools column
VBScript Example
HistoryChart0.IsShowToolBar = True
Left
The left coordinate
Define
Double Left
Example Object's left side of the coordinate values is 100 on the
screen
VBScript Example
HistoryChart0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = HistoryChart0.Name
NumberAxisMaximum
Get or set the maximum scale of numerical axis
Define
Double NumberAxisMaximum
NumberAxisMinimum
Get or set the minimum scale of numerical axis
Define
Double NumberAxisMinimum
NumberInterval
Get or set the large scale of numerical axis
Define
Double NumberInterval
NumberSmallInterval
Get or set the small scale of numerical axis
Define
Double NumberSmallInterval
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
HistoryChart0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
HistoryChart0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
HistoryChart0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example Set the Layer index of the specified object to 3
VBScript Example
HistoryChart0.ZIndex = 3
HMIXYChart
XY chart control
Methods list
Name Description
AddNewLimitLine Add a new limit line
AddPoint New data points
Image array translate into
ArrayToString
string
DeletePoint Delete the data points
DeletevalueAll Delete all the data points
Export Export the visible curve
ExportHistoryData Export history data
ExportRealData Export real-time data
ExportRealData Export real-time data
Look for animation to modify
FindAnimation the associated variables of the
animation
FirstAction The most left
GetDataTable Store data to data table
HiddenSeries Hide curve
HistoryXySeriesExport Export history XY curve
Import Import excel
LastAction The most right
Bottom margin under the
MarginBottom
curve
MarginLeft Left margin of the curve
MarginRight Right margin of the curve
MarginTop Top margin of the curve
NextAction Right shift
Get the path of save which
OpenShowFileDialog
dialog select
PreAction Left shift
Print Print
QueryDate Data query
QueryEndTime Set the end time of the query
data
QueryHistoryDate Query of the historical data
QueryInveral Set the query interval
Set the start time of the query
QueryStartTime
data
QueryUnit Set the query unit
RemoveAllLimitLine Remove all limit line
Save Save
Save Save as pictures
SeriesIsUpdate whether to update the curve
Set the color of points and
SetLimitLinePointColor
curves outside the limit line
Set the color of points and
SetLineAndPointColor
curves
Set the range of the vertical
SetSeriesMultiAxisMaxMin
axis of the multi-axis curve
Curve correlation variable
SetSeriesVariablePath
substitution
SetVarRecordRulerName Set the name of query rule
StartTimer Start timer
StopTimer Stop timer
UpdatePoint Update data point
VisiableSeries Display the curve
XAxisTransformRatio The X axis ratio
XY curvilinear coordinates
XyValueTransform translate into window
coordinates
YAxisTransformRatio The Y axis ratio
Property list
Name Description
DataSize Refresh count
Height Height
IsShow Whether display the specified
object
Whether display the positioning
IsShowBtnCrossLine
line button
IsShowBtnXYClear Whether display the clear button
IsShowBtnXYDown Whether display the down button
Whether display the left shift
IsShowBtnXYLeft
button
Whether display the import and
IsShowBtnXYMenu
export button
IsShowBtnXYPrint Whether display the print button
Whether display the real-time
IsShowBtnXYRelConfig
curve configuration button
Whether display the right shift
IsShowBtnXYRight
button
IsShowBtnXYSave Whether display the save button
Whether display the start or stop
IsShowBtnXYStop
button
IsShowBtnXYUp Whether display the up button
Whether display the history curve
IsShowHtBtnXYConfig
configuration button
Whether display the history curve
IsShowHtBtnXYQuery
query button
Whether display the the status
IsShowStatusBar
column
Whether display the quick time
IsShowXYCbTime
setting button
Whether display the time setting
IsShowXYSetTime
button
Left The left coordinate
Name Name
ToolTip Tooltip text
Top The top coordinate
Width Width
XAxisInterval Get or set the large scale of X
axis
XAxisMaximum Get or set the maximum of X axis
XAxisMinimum Get or set the minimum of X axis
Get or set the small scale of X
XAxisSmallInterval
axis
Get or set the large scale of Y
YAxisInterval
axis
YAxisMaximum Get or set the maximum of Y axis
YAxisMinimum Get or set the minimum of Y axis
Get or set the small scale of Y
YAxisSmallInterval
axis
ZIndex Layer index
AddNewLimitLine
Add new limit line (The "UpperAndLowerDisplay" is checked in the
control property)
Define
AddNewLimitLine(variablePath ,defaultValue ,color , thickness)
Parameter
Data
Name Required/Optional Description
Type
variablePath Required String Variable path
Default value
defaultValue Required Double
(default)
color Required Brush Line fill color
thickness Required Double Line thicknesses
Example
VBScript Example
Call XYchart0.AddNewLimitLine("Var.变
量",90,Colors.Red,5)
AddPoint
Add data point
Define
AddPoint(seriesName ,x ,y)
Parameter
Data
Name Required/Optional Description
Type
seriesName Required String curve name
x Required Double X value
y Required Double Y value
Example
Add data point
VBScript Example
Call XYchart0.AddPoint("Series0",50,50)
ArrayToString
Image array translate into string
Define
ArrayToString(seriesName)
Parameter
Call
ReportCmd.ExportDataByTemplate("D:\Test.xlsx","Report0",XYChart0.ArrayToString
2. The two diferent curve pictures from one realtimechart are exported to the same report
VBScript Example
Call
ReportCmd.ExportDataByTemplate("D:\Test.xlsx","Report0",XYChart0.ArrayToString
Example2
The two diferent curve pictures from two different XYchart are exported to the same report
The operation steps are as follows:
a.Create a XYChart0 in the screen and associate variables that need to be viewed.
b.Create a new report template "Report0", select a cell to associate history variables and time.
c.In the report template, the menu bar --> Realtime Variable --> System --> Image, to add the
corresponding number of curve pictures.
d.Add a button to the created screen and write in the script:
VBScript Example
dt = XYChart0.GetDataTable("SeriesConfig0,SeriesConfig1")
Call
ReportCmd.ExportDataByTemplate("D:\test.xlsx","Report0",dt,XYChart0.ArrayToSt
DeletePoint
Delete data point
Define
DeletePoint(seriesName , itemIndex)
Parameter
Data
Name Required/Optional Description
Type
seriesName Required String Name of curve
select the curve
itemIndex Required int
points' index
Example
Delete data point
VBScript Example
Call XYChart0.DeletePoint("Series0",0)
DeletevalueAll
Delete all data points
Define
DeletevalueAll()
Example
Delete all data points
VBScript Example
Call XY曲线0.DeletevalueAll()
Export
Export the visible curve
Define
Export(exportSeriesName)
Parameter
Name Required/Optional Data Type Description
seriesName Required String The name of the curve
Example
Export the visible curve
VBScript Example
Call XYChart0.Export("Series0,SeriesConfig0,SeriesConfig1")
ExportHistoryData
Export history data
Define
ExportHistoryData(historyseriesName)
Parameter
Data
Name Required/Optional Description
Type
The name of
historyseriesName Required String
curve
Example
Export history data
VBScript Example
Call XYChart0.ExportHistoryData("Series0")
ExportRealData
Export real-time data
Define
ExportRealData(seriesName)
Parameter
Name Required/Optional Data Type Description
seriesName Required String The name of curve
Example
Export real-time data
VBScript Example
Call XYChart0.ExportRealData("Series0")
ExportData
Export data
Define
ExportRealData(seriesName , templateName)
Parameter
Data
Name Required/Optional Description
Type
seriesName Required String The name of curve
The name of report
templateName Required String
template
Example
Export data
VBScript Example
Call XYChart0.ExportRealData("Series0","Report0")
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
XYChart0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
FirstAction
The most left
Define
FirstAction()
Example
The most left
VBScript Example
Call XYChart0.FirstAction()
GetDataTable
Store data to data table
Define
GetDataTable(seriesName)
Parameter
Data
Name Required/Optional Description
Type
Name of the curve, separate by
seriesName Required String
commas
Example
Store data to data table
VBScript Example
dim dt
dt = XYChart0.GetDataTable("SeriesConfig0")
Call ReportCmd.DirectExportDataToExcel(dt,"D:\XYDT.xlsx",1)
HiddenSeries
The hidden curve
Define
HiddenSeries(seriesName)
Parameter
Data
Name Required/Optional Description
Type
Name of the curve,
seriesName Required String
separate by commas
Example
The hidden curve
VBScript Example
Call XYChart0.HiddenSeries("Series0")
HistoryXySeriesExport
Export data
Define
HistoryXySeriesExport(seriesName , templateName)
Parameter
Data
Name Required/Optional Description
Type
seriesName Required String History curve of XY name
The name of report
templateName Required String
template
Example
Export data
VBScript Example
Call XYChart0.HistoryXySeriesExport("Series0","Report0")
Import
Import excel
Define
Import(seriesName)
Parameter
Data
Name Required/Optional Description
Type
The name of the
seriesName Required String
import curve
Example
Import excel
VBScript Example
Call XYChart0.Import("Series0")
LastAction
The most right
Define
LastAction()
Example
The most right
VBScript Example
Call XYChart0.LastAction()
MarginBottom
Bottom margin under the curve
Define
MarginBottom()
Example
Bottom margin under the curve
VBScript Example
Button0.Content = XYChart0.MarginBottom()
MarginLeft
Left margin of the curve
Define
MarginLeft()
Example
Left margin of the curve
VBScript Example
Button0.Content = XYChart0.Marginleft()
MarginRight
Right margin of the curve
Define
MarginRight()
Example
Right margin of the curve
VBScript Example
Button0.Content = XYChart0.MarginRight()
MarginTop
Top margin of the curve
Define
MarginTop()
Example
Top margin of the curve
VBScript Example
Button0.Content = XYChart0.MarginTop()
NextAction
Right shift
Define
NextAction()
Example
Right shift
VBScript Example
Call XYChart0.NextAction()
OpenShowFileDialog
Get the saved path which selected by dialog box
Define
OpenShowFileDialog()
Example
Get saved path which selected by dialog box
VBScript Example
tt = XYChart0.OpenShowFileDialog()
Call
ReportCmd.ExportDataByTemplate(tt,"Report0",XYChart0.ArrayToString("Series0")&
PreAction
Left shift
Define
PreAction()
Example
Left shift
VBScript Example
Call XYChart0.PreAction()
Print
Print
Define
Print()
Example
Print
VBScript Example
Call XYChart0.Print()
QueryDate
Query history data
Define
QueryDate()
Example
1.Query the historical data(Timing record)
VBScript Example
Call
XYChart0.QueryStartTime(DateTimePicker0.ValueTime)
Call
XYChart0.QueryEndTime(DateTimePicker1.ValueTime)
Call XYChart0.SetVarRecordRulerName("s1")
Call XYChart0.QueryHistoryDate()
Call
XYChart0.QueryStartTime(DateTimePicker0.ValueTime)
Call
XYChart0.QueryEndTime(DateTimePicker1.ValueTime)
Call XYChart0.QueryHistoryDate()
Call
XYChart0.QueryStartTime(DateTimePicker0.ValueTime)
Call
XYChart0.QueryEndTime(DateTimePicker1.ValueTime)
Call XYChart0.QueryInveral(1)
Call XYChart0.QueryUnit(0)
Call XYChart0.QueryHistoryDate()
QueryEndTime
Set the end time of the query data
Define
QueryEndTime(dt)
Parameter
Name Required/Optional Data Type Description
dt Required DateTime End time
Example
Set the end time of the query data
VBScript Example
Call
XYChart0.QueryStartTime(DateTimePicker0.ValueTime)
Call
XYChart0.QueryEndTime(DateTimePicker1.ValueTime)
Call XYChart0.QueryInveral(1)
Call XYChart0.QueryUnit(0)
Call XYChart0.QueryHistoryDate()
QueryHistoryDate
Query history data
Define
QueryHistoryDate(startTime , endTime , inveralTime , index)
Parameter
Data
Name Required/Optional Description
Type
startTime Required DateTime Start time
endTime Required DateTime End time
inveralTime Required Int Time interval
Time interval unit(Value of 0-5,Corresponding to s、
index Required Int
mi、h、d、m、y)
Example
1.Query the historical data(Timing record)
VBScript Example
Call XYChart0.SetVarRecordRulerName("s1")
Call
XYChart0.QueryHistoryDate(DateTimePicker0.ValueTime,DateTimePicker1.ValueTime
2.Query the historical data(Change record) or Query the historical group data
VBScript Example
Call
XYChart0.QueryHistoryDate(DateTimePicker0.ValueTime,DateTimePicker1.ValueTime
QueryInveral
Set the query interval
Define
QueryInveral(inveral)
Parameter
Name Required/Optional Data Type Description
inveral Required Int Time interval
Example
Query the historical group data
VBScript Example
Call
XYChart0.QueryStartTime(DateTimePicker0.ValueTime)
Call
XYChart0.QueryEndTime(DateTimePicker1.ValueTime)
Call XYChart0.QueryInveral(1)
Call XYChart0.QueryUnit(0)
Call XYChart0.QueryHistoryDate()
QueryStartTime
Set the start time of the data query
Define
QueryStartTime(dt)
Parameter
Name Required/Optional Data Type Description
dt Required DateTime start time
Example
Query the historical group data
VBScript Example
Call
XYChart0.QueryStartTime(DateTimePicker0.ValueTime)
Call
XYChart0.QueryEndTime(DateTimePicker1.ValueTime)
Call XYChart0.QueryInveral(1)
Call XYChart0.QueryUnit(0)
Call XYChart0.QueryHistoryDate()
QueryUnit
Set the query unit
Define
QueryUnit(index)
Parameter
Data
Name Required/Optional Description
Type
Time interval unit(Value of 0-
index Required Int 5,Corresponding to s、mi、h、
d、m、y)
Example
Query the historical group data
VBScript Example
Call
XYChart0.QueryStartTime(DateTimePicker0.ValueTime)
Call
XYChart0.QueryEndTime(DateTimePicker1.ValueTime)
Call XYChart0.QueryInveral(1)
Call XYChart0.QueryUnit(0)
Call XYChart0.QueryHistoryDate()
RemoveAllLimitLine
Remove all limit line
Define
RemoveAllLimitLine()
Example
Remove all limit line
VBScript Example
Call XYChart0.RemoveAllLimitLine()
Save
Save
Define
Save()
Example
Save
VBScript Example
Call XYChart0.Save()
Save
Save as pictures
Define
Save(path , seriesName)
Parameter
Data
Name Required/Optional Description
Type
path Required String Absolute path
The name of curve,
seriesName Required String
separate by commas
Example
Save
VBScript Example
Call XYChart0.Save("D:\test.jpg","Series0")
SeriesIsUpdate
Whether to update the curve
Define
SeriesIsUpdate(seriesName ,isUpdate)
Parameter
Data
Name Required/Optional Description
Type
The name of curve,
seriesName Required String
separate by commas
isUpdate Required Bool whether to update
Example
Whether to update the curve
VBScript Example
Call XYChart0.SeriesIsUpdate("Series0",True)
SetLimitLinePointColor
Set the color of points and curves outside the limit line
Define
SetLimitLinePointColor(maxVariablePath , minVariablePath ,brush )
Parameter
Data
Name Required/Optional Description
Type
Variable path of the maximum value of the
maxVariablePath Required String
limit line
Variable path of the minimum value of the
minVariablePath Required String
limit line
brush Required Brush New color of the points and curves
Example
Set the color of points and curves outside the limit line
Note: LINE+Metro+this script: Ten sections of different colors of points and curves update
Circularly
LINE+Custom+this script: The points and curves colors outside the limit line are the color set
by the script
LINE+Normal+this script: The points color outside the limit line are the color set by the script,
and the curves color don't change.
VBScript Example
Call
XYChart0.SetLimitLinePointColor("Var.XY.up","Var.XY.Lower",Colors.Red)
SetLineAndPointColor
Set the color of points and curves
Define
SetLineAndPointColor(brush )
Parameter
Data
Name Required/Optional Description
Type
New color of the points and
brush Required Brush
curves
Example
Set the color of points and curves
Note: LINE+Metro+this script: Ten sections of different colors of
points and curves update Circularly
LINE+Custom+this script: The points and curves colors are the color
set by the script
LINE+Normal+this script: The points color are the color set by the
script, and the curves color don't change.
VBScript Example
Call XYChart0.SetLineAndPointColor(Colors.Red)
SetSeriesMultiAxisMaxMin
Set the range of the vertical axis of the multi-axis curve
Define
SetSeriesMultiAxisMaxMin(seriesName , max , min)
Parameter
Name Required/Optional Data Type Description
seriesName Required String Curve name
max Required Double Set the max value
min Required Double Set the min value
Example
Set the maximum and minimum values of the vertical axis of the multi-
axis curve Series0 to 120 and -20 respectively
VBScript Example
call
XYChart0.SetSeriesMultiAxisMaxMin("Series0",120,-20)
SetSeriesVariablePath
Curve correlation variable substitution
Define
SetSeriesVariablePath(relpathList,htpathList)
Parameter
Data
Name Required/Optional Description
Type
The new variable path of the real-time variables that replace
relpathList Required String the old variables,group X and Y variables are separated by a
semicolon,variable groups are separated by commas
The new variable path of the history variables that replace the
htpathList Required String old variables,group X and Y variables are separated by a
semicolon,variables groups are separated by commas
Example
VBScript Example
Call
XYChart0.SetSeriesVariablePath("Var.variable0;Var.variable1","HistoryRecord;Hi
SetVarRecordRulerName
Set the name of query rule
Define
SetVarRecordRulerName(RuleName)
Parameter
Name Required/Optional Data Type Description
RuleName Required String The name of timer
Example
1.Set the name of query rule,s1 is the timer name
VBScript Example
Call XYChart0.SetVarRecordRulerName("s1")
Call
XYChart0.QueryStartTime(DateTimePicker0.ValueTime)
Call
XYChart0.QueryEndTime(DateTimePicker1.ValueTime)
Call XYChart0.SetVarRecordRulerName("s1")
Call XYChart0.QueryHistoryDate()
StartTimer
Start timer
Define
StartTimer()
Example
Start timer
VBScript Example
Call XYChart0.StartTimer()
StopTimer
Stop timer
Define
StopTimer()
Example
Stop timer
VBScript Example
Call XYChart0.StopTimer()
UpdatePoint
Update data point
Define
UpdatePoint(seriesName ,itemIndex , x , y)
Parameter
Data
Name Required/Optional Description
Type
Name of curve,
seriesName Required String
separate by commas
itemIndex Required Int Select the curve index
x Required Double Data point
y Required Double Data point
Example
VBScript Example
Call XYChart0.UpdatePoint("Series0",0,50,50)
VisiableSeries
Display curves
Define
VisiableSeries(seriesName)
Parameter
Data
Name Required/Optional Description
Type
Name of the curve,
seriesName Required String
separate by commas
Example
Display curves
VBScript Example
Call XYChart0.VisiableSeries("Series0")
XAxisTransformRatio
The X axis ratio
Define
XAxisTransformRatio()
Example
The X axis ratio
VBScript Example
Button0.Content = XYChart0.XAxisTransformRatio()
XyValueTransform
XY curvilinear coordinates into window coordinates
Define
XyValueTransform(xy)
Parameter
Data
Name Required/Optional Description
Type
Coordinates type string,
seriesName Required String
such as "20,20"
Example
XY curvilinear coordinates into window coordinates
VBScript Example
Button0.Content =
XYChart0.XyValueTransform("20,20")
YAxisTransformRatio
The Y axis ratio
Define
YAxisTransformRatio()
Example
The Y axis ratio
VBScript Example
Button0.Content = XYChart0.YAxisTransformRatio()
DataSize
Refresh count
Define
int DataSize
Example
Set the refreshing count to 10
VBScript Example
XYchart0.DataSize = 10
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
XYchart0.Height = 100
IsShow
Whether display the specified object
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
XYchart0.IsShowBtnCrossLine = True
IsShowBtnXYClear
Whether display the Clear Button
Define
Boolean IsShowBtnXYClear
Example
Display the Clear Button
VBScript Example
XYchart0.IsShowBtnXYClear = True
IsShowBtnXYDown
Whether display the down button
Define
Boolean IsShowBtnXYDown
Example
Display the down button
VBScript Example
XYchart0.IsShowBtnXYDown = True
IsShowBtnXYLeft
Whether display the left shift button
Define
Boolean IsShowBtnXYLeft
Example
Display the left shift button
VBScript Example
XYchart0.IsShowBtnXYLeft = True
IsShowBtnXYMenu
Whether display the import and export button
Define
Boolean IsShowBtnXYMenu
Example
Display the import and export button
VBScript Example
XYchart0.IsShowBtnXYMenu = True
IsShowBtnXYPrint
Whether display the print button
Define
Boolean IsShowBtnXYPrint
Example
Display the print button
VBScript Example
XYchart0.IsShowBtnXYPrint = True
IsShowBtnXYRelConfig
Whether display the real-time curve configuration button
Define
Boolean IsShowBtnXYRelConfig
Example
Display the real-time curve configuration button
VBScript Example
XYchart0.IsShowBtnXYRelConfig = True
IsShowBtnXYRight
Whether display the right shift button
Define
Boolean IsShowBtnXYRight
Example
Display the right shift button
VBScript Example
XYchart0.IsShowBtnXYRight = True
IsShowBtnXYSave
Whether display the save button
Define
Boolean IsShowBtnXYSave
Example
Display the save button
VBScript Example
XYchart0.IsShowBtnXYSave = True
IsShowBtnXYStop
Whether display the start or stop button
Define
Boolean IsShowBtnXYStop
Example
Display the start or stop button
VBScript Example
XYchart0.IsShowBtnXYStop = True
IsShowBtnXYUp
Whether display the up button
Define
Boolean IsShowBtnXYUp
Example
Display the up button
VBScript Example
XYchart0.IsShowBtnXYUp = True
IsShowHtBtnXYConfig
Whether display the history curve configuration button
Define
Boolean IsShowHtBtnXYConfig
Example
Display the history curve configuration button
VBScript Example
XYchart0.IsShowHtBtnXYConfig = True
IsShowHtBtnXYQuery
Whether display the history curve query button
Define
Boolean IsShowHtBtnXYQuery
Example
Display the history curve query button
VBScript Example
XYchart0.IsShowHtBtnXYQuery = True
IsShowStatusBar
Whether display the status column
Define
Boolean IsShowStatusBar
Example
Display the status column
VBScript Example
XYchart0.IsShowStatusBar = True
IsShowXYCbTime
Whether display the quick time setting button
Define
Boolean IsShowXYCbTime
Example
Display the quick time setting button
VBScript Example
XYchart0.IsShowXYCbTime = True
IsShowXYSetTime
Whether display the time setting button
Define
Boolean IsShowXYSetTime
Example
Display the time setting button
VBScript Example
XYchart0.IsShowXYSetTime = True
Left
The left coordinate
Define
Double Left
Example Object's left side of the coordinate values is 100 on the
screen
VBScript Example
XYchart0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = XYchart0.Name
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
XYchart0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
XYchart0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
XYchart0.Width = 100
XAxisInterval
Get or set the large scale of X axis(The interval between two
adjacent large scale lines)
Define
Double XAxisInterval
Example Set the large scale of X axis to 20
VBScript Example
XYchart0.XAxisInterval = 20
XAxisMaximum
Get or set the maximum value of X axis
Define
Double XAxisMaximum
Example Set the maximum value of X axis to120
VBScript Example
XYchart0.XAxisMaximum = 120
XAxisMinimum
Get or set the minimum value of X axis
Define
Double XAxisMinimum
Example Set the minimum value of X axis to 20
VBScript Example
XYchart0.XAxisMinimum = 20
XAxisSmallInterval
Get or set the small scale of X axis(The number of small scale lines
between two adjacent large scale lines.)
Define
Double XAxisSmallInterval
Example Set the small scale of X axis to 4
VBScript Example
XYchart0.XAxisSmallInterval = 4
YAxisInterval
Get or set the large scale of Y axis(The interval between two
adjacent large scale lines)
Define
Double YAxisInterval
Example Set the large scale of Y axis to 20
VBScript Example
XYchart0.YAxisInterval = 20
YAxisMaximum
Get or set the maximum value of Y axis
Define
Double YAxisMaximum
Example
Set the maximum value of Y axis to 120
VBScript Example
XYchart0.YAxisMaximum = 120
YAxisMinimum
Get or set the minimum value of Y axis
Define
Double YAxisMinimum
Example set the minimum value of Y axis to 20
VBScript Example
XYchart0.YAxisMinimum = 20
YAxisSmallInterval
Get or set the minimum scale of Y axis(The number of small scale
lines between two adjacent large scale lines.)
Define
Double YAxisSmallInterval
Example Set the small scale of Y axis to 4
VBScript Example
XYchart0.YAxisSmallInterval = 4
ZIndex
Layer index
Define
Int32 ZIndex
Example Set the Layer index of the specified object to 3
VBScript Example
XYchart0.ZIndex = 3
HMICustomChart
Customized chart control
Methods list
Name Description
AddNewLimitLine Add new limit line
Calculate the specific
values of the upper
CalculateValue
and lower control
lines
Each curve is
associated with a
CategoryPointCount
variable, and refresh
at the same time
Time and data load
ContrastDataLoad
contrastively
Set coordinates of
CustomAxisLabel
string axis
The loading of the
DataTableDataLoad curve whose data
source is DataTable
Export history curve
ExportHistorySeriesData
with report template
Export the curve
ExportItemSourceAsDataTable whose data source is
DataTable
Export real-time
ExportRelSeriesData curve with report
template
Export customized
ExportSeriesData
curves
Lo ok for animation
to modify the
FindAnimation
associated variables
of the animation
HistorySeries Load history curve
HistorySortXYSeries Load sorted historical
XY curve
Load history XY
HistoryXYSeries
curve
ImportSeriesData Import curves
Print Print
Query history XY
QueryDataXYFromDataBase
curve
Column graph
RealTimeFixedTimeSeries
superposition curve
Load real-time XY
RealTimeXYPoint
data
Query real-time
RelTimeSeries
curve
Query real-time XY
RelTimeXYSeries
curve
Load points of the
RelTimeXYUpdateSeries
real-time XY curve
RemoveAllLimitLine Remove all limit line
Save Save
SetActiveSeriesNo Set current curve
Set title Color of the
SetChartHeaderColor
chart
Set legend position
SetChartLegendPosition
of the chart
Setting the major grid
SetChartMajorGridLine
line
Setting the major grid
SetChartMinorGridLine
line
Set the refresh cycle
SetPeroidRefreshTime
of the curve
SetPeroidStartTime Set the start time
SetPeroidTimeRange Set time range
SetSeriesLegendDisplay Set whether to
display legend of a
curve
Set symbol text color
SetSymbolTextColor
of the curve
Get the column
SetTableNameForColumns name of data source
in the data table
Set the name of
SetVarRecordRulerName
query rule
Initialize the
SetXAxisRange
transverse
Set whether the
SetYAxisAutoChanged vertical axis can
automatically adjust
Query of the history
ShowQueryChartTimeBetweenData
curve
Contrast of the real
ShowRelativeChartTime
time history curve
StartSeries Start loading curve
StopSeries Stop loading curve
Property list
Name Description
Height Height
Whether display the specified object or
IsShow
not
Left The left coordinate
Name Name
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
AddNewLimitLine
Add new limit line (The "UpperAndLowerDisplay" is checked in the control
property)
Define
AddNewLimitLine(variablePath ,defaultValue ,color , thickness)
Parameter
VBScript Example
Call
CustomChart0.AddNewLimitLine("Var.variable",0,Colors.Red,5)
CalculateValue
Calculate the specific values of the upper and lower control lines
Define
CalculateValue(count , variablePath1 , variablePath2 , number)
Parameter
Data
Name Required/Optional Description
Type
count Required Int Value count
variablePath1 Required String Variable path
variablePath2 Required String Variable path
The multiple of the standard
number Required Int
deviation
Example
Calculate the specific values of the upper and lower control lines
Note: Each 20 data is refreshed, then calculate specified value and assigned to two
Variable;
The upper and lower limit is related to Var.Variable and Var.Variable1 respectively.
VBScript Example
Call
CustomChart0.CalculateValue(20,"Var.Variable","Var.Variable1",1)
CategoryPointCount
Each curve is associated with a variable, and refresh at the same time
Define
CategoryPointCount(seriesno ,cnames , variablePaths)
Parameter
VBScript Example
Call
CustomChart0.CategoryPointCount(0,"0,1,2","Var.Custom.variable,Var.Custom.vari
Call CustomChart0.SetPeroidRefreshTime(1000)
ContrastDataLoad
Time and data load contrastively
Define
ContrastDataLoad(table , timeInterval , labindex , indexs)
Parameter
VBScript Example
dt=
ReportCmd.DirectImportToDataTable("E:\test.xlsx")
'Import Excel to DataTable
Call CustomChart0.ContrastDataLoad(dt,1,0,"1,2,3")
CustomAxisLabel
Set coordinates of string axis
Define
CustomAxisLabel(index , cnames)
Parameter
Data
Name Required/Optional Description
Type
The value is 0 or 1, indicating that
index Required Int the String axis is a horizontal axis
or a vertical axis.
The coordinates, separated by
cnames Required String
commas
Example
Set coordinates of string Axis : one,two,three
Note:The sample of "customchart.xlsx" as shown in the following figure
VBScript Example
dt=
ReportCmd.DirectImportToDataTable("E:\customchart.xlsx")
'Import Excel to DataTable
Call CustomChart0.DataTableDataLoad(dt,0,0,1)
Call CustomChart0.CustomAxisLabel(0,"one,two,three")
DataTableDataLoad
The loading of the curve whose data source is DataTable
Define
DataTableDataLoad(table , seriesIndex , xbingingIndex , ybingingIndex)
Parameter
VBScript Example
dt=
ReportCmd.DirectImportToDataTable("E:\customchart.xlsx")
'Import Excel to DataTable
Call CustomChart0.DataTableDataLoad(dt,0,0,1)
ExportHistorySeriesData
Export history curve with report template
Define
ExportHistorySeriesData(seriesName ,templateName , variableList)
Parameter
Name Required/Optional Data Type Description
seriesName Required String curve name
templateName Required String template name
variableList Required String variable name
Example
Export the history curve Series0,Associated variables are:"Var.variable0"
VBScript Example
Call
CustomChart0.ExportHistorySeriesData("Series0","report0","Var.Variable0")
ExportItemSourceAsDataTable
Export the curve whose data source is DataTable
Define
ExportItemSourceAsDataTable(seriesName)
Parameter
Name Required/Optional Data Type Description
seriesName Required String The curve name
Example
Export history curve
Note:the data source of Series0 is DataTable
VBScript Example
Call CustomChart0.ExportItemSourceAsDataTable("Series0")
ExportRelSeriesData
Export real-time curve with report template
Define
ExportRelSeriesData(seriesName ,templateName)
Parameter
Name Required/Optional Data Type Description
seriesName Required String The curve name
templateName Required String The template name
Example
Export real-time curve with report template
VBScript Example
Call
CustomChart0.ExportRelSeriesData("Series0","report0")
ExportSeriesData
Export customized curves
Define
ExportSeriesData(seriesName)
Parameter
Data
Name Required/Optional Description
Type
The name of
seriesName Required String curves,separate
by commas
Example
Export customized curves Series0,Series1
VBScript Example
Call
CustomChart0.ExportSeriesData("Series0,Series1")
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
CustomChart0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
HistorySeries
Load history curve
Define
HistorySeries(seriesno , startTime , endTime , intervalTime , intervalUnit , variablePath)
Parameter
Call CustomChart0.SetVarRecordRulerName("s1")
Call
CustomChart0.HistorySeries(2,DateTimePicker0.ValueTime,DateTimePicker1.ValueTi
Call
CustomChart0.HistorySeries(4,DateTimePicker0.ValueTime,DateTimePicker1.ValueTi
HistorySortXYSeries
Load sorted historical XY curve
Define
HistorySortXYSeries(seriesno , startTime , endTime , intervalTime , intervalUnit , variableXPaths ,
variableYPaths)
Parameter
Call CustomChart0.SetVarRecordRulerName("s1")
Call
CustomChart0.HistorySortXYSeries(3,DateTimePicker0.ValueTime,DateTimePicker1.V
Call
CustomChart0.HistorySortXYSeries(5,DateTimePicker0.ValueTime,DateTimePicker1.V
HistoryXYSeries
Load history XY curve
Define
HistoryXYSeries(seriesno , startTime , endTime , intervalTime , intervalUnit , variableXPaths ,
variableYPaths)
Parameter
Call CustomChart0.SetVarRecordRulerName("s1")
Call
CustomChart0.HistoryXYSeries(3,DateTimePicker0.ValueTime,DateTimePicker1.Value
Call
CustomChart0.HistoryXYSeries(5,DateTimePicker0.ValueTime,DateTimePicker1.Value
ImportSeriesData
Import curves
Define
ImportSeriesData(seriesIndex ,XAxisType)
Parameter
Data
Name Required/Optional Description
Type
Curve index(When there
seriesIndex Required String are more curves, separate
by commas)
Horizontal axis
XAxisType Required String classification
("Time","Double","String")
Example
Import Series0 curve,horizontal axis type is"Time"
VBScript Example
Call CustomChart0.ImportSeriesData("0","Time")
Print
Print
Define
Print()
Example
Print customize curves
VBScript Example
Call CustomChart0.Print()
QueryDataXYFromDataBase
Query history XY curves(Historical cohort record the query script)
Define
QueryDataXYFromDataBase(seriesno , startTime , endTime , count)
Parameter
VBScript Example
Data
Name Required/Optional Description
Type
seriesno Required Int The curve index
tableName Required String Database table name
startTime Required DateTime Query start time
endTime Required DateTime Query end time
columnNames Required String Column name
Format: 2 represents the period is year; 3 represents
rangeFormat Required Int
the period is month
Example
Column graph superposition curve(histoty group record)
VBScript Example
Call
CustomChart0.RealTimeFixedTimeSeries("0,1,2","bbb",DateTimePicker8.ValueTime,D
Call CustomChart0.SetPeroidRefreshTime(1000)
RealTimeXYPoint
Load real-time XY data(History group record the query script)
Define
RealTimeXYPoint(seriesno , interval , startLocation , endLocation)
Parameter
VBScript Example
Call
CustomChart0.SetTableNameForColumns("aaa","RecordVariable","RecordVariable1",0
Call CustomChart0.RealTimeXYPoint(0,10,0,100)
Call CustomChart0.SetPeroidRefreshTime(1000)
RealTimeSeries
Query real-time curve
Define
RelTimeSeries(seriesno , variablePaths)
Parameter
Name Required/Optional Data Type Description
seriesno Required Int Curve index
variablePaths Required Double Variable index
Example
Query real-time curve
VBScript Example
Call CustomChart0.SetPeroidTimeRange(100)
Call CustomChart0.RelTimeSeries(0,"Var.variable")
Call CustomChart0.SetPeroidRefreshTime(1000)
RelTimeXYSeries
Query real-time XY curve
Define
RelTimeSeries(seriesno , variableXPaths , variableYPaths)
Parameter
Name Required/Optional Data Type Description
seriesno Required Int Curve index
variableXPaths Required String X variable path
variableYPaths Required String Y variable path
Example
Query real-time XY curve
VBScript Example
Call
CustomChart0.RelTimeXYSeries(0,"Var.variable","Var.variable1")
Call CustomChart0.SetPeroidRefreshTime(1000)
RelTimeXYUpdateSeries
Load points of the real-time XY curve
Define
RelTimeXYUpdateSeries(seriesno , variableCPaths , variableXPaths,variableYPaths)
Parameter
VBScript Example
Call CustomChart0.SetPeroidRefreshTime(1000)
Call
CustomChart0.RelTimeXYUpdateSeries(1,"Var.VAriable2","Var.CustomChart.custom"
Call CustomChart0.RemoveAllLimitLine()
Save
Save
Define
Save()
Example
Save customize curve
VBScript Example
CustomChart0.Save()
SetActiveSeriesNo
Set current curve
Define
SetActiveSeriesNo(seriesno)
Parameter
Data
Name Required/Optional Description
Type
Curve index,Start from
seriesno Required Int
0
Example
Set current curve
VBScript Example
Call CustomChart0.SetActiveSeriesNo(1)
SetChartHeaderColor
Set title Color of the chart
Define
SetChartHeaderColor(color)
Parameter
Name Required/Optional Data Type Description
color Required Brush Setting color
Example
Set title Color of the chart
VBScript Example
Call CustomChart0.SetChartHeaderColor(Colors.Blue)
SetChartLegendPosition
Set legend position of the chart
Define
SetChartLegendPosition(positionIndex , InsideOrOutside)
Parameter
Data
Name Required/Optional Description
Type
The value is 0,1,2,3,
indicating the position
positionIndex Required Int
is left, upper, right,
and lower.
The value is 0 or 1,
indicating that the
InsideOrOutside Required Int
legend is outside or
inside the chart.
Example
Set the legend position in the right side of the chart
VBScript Example
Call CustomChart0.SetChartLegendPosition(2,1)
SetChartMajorGridLine
Setting the major grid line
Define
SetChartMajorGridLine(color , thickness , collection)
Parameter
Data
Name Required/Optional Description
Type
color Required Brush Grid line color
thickness Required Double Grid line thickness
Dotted line format, separate by
collection Required String
a commas. Example"2,4"
Example
VBScript Example
Call
CustomChart0.SetChartMajorGridLine(Colors.Pink,3,"2,4")
SetChartMinorGridLine
Setting the minor grid line
Define
SetChartMinorGridLine(color , thickness,collection)
Parameter
Data
Name Required/Optional Description
Type
color Required Brush Grid line color
thickness Required Double Grid line thickness
Dotted line format, separate by a commas.
collection Required String
Example"2,4"
Example
VBScript Example
Call
CustomChart0.SetChartMinorGridLine(Colors.YellowGreen,1,"3,5")
SetPeroidRefreshTime
Set the curve refresh interval
Define
SetPeroidRefreshTime(ms)
Parameter
Name Required/Optional Data Type Description
ms Required Int unit ms
Example
query real-time curve
VBScript Example
Call CustomChart0.SetPeroidTimeRange(100)
Call CustomChart0.RelTimeSeries(0,"Var.Varible")
Call CustomChart0.SetPeroidRefreshTime(1000)
SetPeroidStartTime
Set start time
Define
SetPeroidStartTime(Time)
Parameter
Name Required/Optional Data Type Description
ms Required Int Unit ms
Example
Set start time
VBScript Example
Call CustomChart0.SetPeroidStartTime()
SetPeroidTimeRange
Set time range
Define
SetPeroidTimeRange(ms)
Parameter
Name Required/Optional Data Type Description
ms Required Int Unit ms
Example
Set time range
VBScript Example
Call CustomChart0.SetPeroidTimeRange(100)
SetSeriesLegendDisplay
Set whether to display legend of a curve
Define
SetSeriesLegendDisplay(seriesIndex , isShow)
Parameter
Data
Name Required/Optional Description
Type
seriesIndex Required Int Curve index
True:display
isShow Required Bool legend;False:do not
display legend
Example
Do not display legend of the curve0
VBScript Example
Call CustomChart0.SetSeriesLegendDisplay(0,False)
SetSymbolTextColor
Set symbol text color of the curve
Define
SetSymbolTextColor(serisesIndex , color)
Parameter
Name Required/Optional Data Type Description
seriesIndex Required Int Curve index
color Required Brush Symbol text color
Example
Set symbol text color of the curve to red
VBScript Example
Call CustomChart0.SetSymbolTextColor(0,Colors.Red)
SetTableNameForColumns
Get the column name of data source in the data table
Define
SetTableNameForColumns(tableName ,xcolumnName , ycolumnName , fixType)
Parameter
Data
Name Required/Optional Description
Type
tableName Required String History group name
The horizontal axis data source column name(The name
xcolumnName Required String
of history record、"Time")
The vertical axis data source column name,that is name
ycolumnName Required String
of history record
Type Required Int 0 means fixed X axis;1 meansvariable X axis
Example
1.Get the column name of data source in the data table
VBScript Example
Call CustomChart0.SetTableNameForColumns("aaa","Time","RecordVariable",0)
Call
CustomChart0.SetTableNameForColumns("aaa","RecordVariable","RecordVariable1",0
SetVarRecordRulerName
Set the name of query rule
Define
SetVarRecordRulerName(RuleName)
Parameter
Call CustomChart0.SetVarRecordRulerName("s1")
Call CustomChart0.SetVarRecordRulerName("s1")
Call
CustomChart0.HistorySeries(2,DateTimePicker0.ValueTime,DateTimePicker1.V
SetXAxisRange
Initialize the transverse,used to initialize icons' transverse range
such as the annual report, monthly report and weekly report etc, and
curve points information
Define
SetXAxisRange(range)
Parameter
Data
Name Required/Optional Description
Type
The values are 0、1、2、3、4、
range Required Int 5,correspond year、month、
week、day、hour、minute
Example
VBScript Example
Call CustomChart0.SetXAxisRange(0)
SetYAxisAutoChanged
Set whether the vertical axis can automatically adjust
Define
SetYAxisAutoChanged(autoChanged)
Parameter
Name Required/Optional Data Type Description
autoChanged Required Bool True or False
Example
Set the vertical axis can automatically adjust
VBScript Example
Call CustomChart0.SetYAxisAutoChanged(True)
ShowQueryChartTimeBetweenData
Query history curve
Define
ShowQueryChartTimeBetweenData(seriesno ,startTime , endTime)
Parameter
Name Required/Optional Data Type Description
seriesno Required Int Curve index
startTime Required DateTime Query start time
endTime Required DateTime Query end time
Example
Query history curve
VBScript Example
Call CustomChart0.SetTableNameForColumns("aaa","Time","RecordVariable",0)
Call
CustomChart0.ShowQueryChartTimeBetweenData(0,DateTimePicker0.ValueTime,DateTim
ShowRelativeChartTime
Real-time curve configuration
Define
ShowRelativeChartTime(seriesno ,startTime , endTime ,rstartTime , rendTime)
Parameter
Call CustomChart0.SetTableNameForColumns("aaa","Time","RecordVariable",0)
Call
CustomChart0.ShowRelativeChartTime("0,1",DateTimePicker0.ValueTime,DateTimePic
Call CustomChart0.SetPeroidRefreshTime(1000)
StartSeries
Start loading curves
Define
StartSeries()
Example
Start loading curves
VBScript Example
CustomChart0.StartSeries()
StopSeries
Stop loading curves
Define
StopSeries()
Example
Stop loading curves
VBScript Example
CustomChart0.StopSeries()
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
CustomChart0.Height = 100
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
CustomChart0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
Text0.Text = CustomChart0.Name
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
CustomChart0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
CustomChart0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
CustomChart0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example Set the Layer index of the specified object to 2
VBScript Example
CustomChart0.ZIndex = 2
HMIPieChart
Pie chart control
Methods list
Name Description
Look for animation to modify the
FindAnimation
associated variables of the animation
Property list
Name Description
Height Height
Whether display the specified object or
IsShow
not
Left The left coordinate
Name Name
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
PieChart0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
PieChart0.Height = 100
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
PieChart0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
Text0.Text = PieChart0.Name
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
PieChart0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
PieChart0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
PieChart0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example Set the Layer index of the specified object to 2
VBScript Example
PieChart0.ZIndex = 2
HMIPieChart3D
3D pie chart control
Methods list
Name Description
Look for animation to modify the
FindAnimation associated variables of the
animation
Curve correlation variable
SetSeriesVariablePath
substitution
StartTimer Start timer
StopTimer Stop timer
Property list
Name Description
Height Height
IsShow Whether display the specified object
Left The left coordinate
Name Name
Get or set the 3D pie chart rotation
Rotation
angle
Tilt Get or set the 3D pie chart angle
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
PieChart3D0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
SetSeriesVariablePath
Curve correlation variable substitution
Define
SetSeriesVariablePath(pathList)
Parameter
Data
Name Required/Optional Description
Type
The new variable path of the variables that replace
pathList Required String
the old variables , separate by commas
Example
Curve correlation variable substitution
VBScript Example
Call PieChart3D0.SetSeriesVariablePath("Var.variable0,Var.variable1")
StartTimer
Start timer
Define
StartTimer()
Example
Start Timer
VBScript Example
Call PieChart3D0.StartTimer()
StopTimer
Stop timer
Define
StopTimer()
Example
Stop Timer
VBScript Example
Call PieChart3D0.StopTimer()
Default.
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
PieChart3D0.Height = 100
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
PieChart3D0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
Text0.Text = PieChart3D0.Name
Rotation
Get or set the 3D pie chart rotation angle
Double Rotation
Print()
Example
Set the rotation Angle of the specified object to 90
VBScript Example
PieChart3D0.Rotation = 90
Tilt
Get or set the 3D pie chart angle
Double Tilt
Print()
Example
Set the Angle of the specified object to 30
VBScript Example
PieChart3D0.Tilt = 30
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
PieChart3D0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
PieChart3D0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
PieChart3D0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example Set the Layer index of the specified object to 2
VBScript Example
PieChart3D0.ZIndex = 2
HMIColumnChart
Column chart control
Methods list
Name Description
AddNewLimitLine Add a new limit line
Look for animation to modify the
FindAnimation
associated variables of the animation
RemoveAllLimitLine Remove all the limit lines
Property list
Name Description
Height Height
IsShow Whether display the specified object
Left The left coordinate
Name Name
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
AddNewLimitLine
Add a new limit line (The "UpperAndLowerDisplay" is checked in the control
property)
Define
AddNewLimitLine(variablePath ,defaultValue ,color , thickness)
Parameter
VBScript Example
Call
ColumnChart0.AddNewLimitLine("Var.Variable",0,Colors.Red,5)
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
ColumnChart0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
RemoveAllLimitLine
Remove all the limit lines
Define
RemoveAllLimitLine()
Example
Remove all the limit line
VBScript Example
Call ColumnChart0.RemoveAllLimitLine()
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
ColumnChart0.Height = 100
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
ColumnChart0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
Text0.Text = ColumnChart0.Name
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
ColumnChart0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
ColumnChart0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
ColumnChart0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example Set the Layer index of the specified object to 2
VBScript Example
ColumnChart0.ZIndex = 2
HMIHistoryColumnChart
History column chart control
Methods list
Name Description
AddNewLimitLine Add a new limit line
Look for animation to
modify the associated
FindAnimation
variables of the
animation
Print Print
Query Query history data
Save Save
Set the start and end
SetDateConditionListStartEndTime
time
Replace the variables
SetSeriesVariablePath associated with the
curve
Property list
Name Description
Height Height
Whether display the specified
IsShow
object or not
Left The left coordinate
Name Name
Get or set the maximum of the
NumberAxisMaximum
number axis
Get or set the minimum of the
NumberAxisMinimum
number axis
The large scale of the numerical
NumberInterval
axis
The small scale of the numerical
NumberSmallInterval
axis
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
AddNewLimitLine
Add a new limit line (upper and lower limit display in control properties is checked)
Define
AddNewLimitLine(variablePath ,defaultValue ,color , thickness)
Parameter
VBScript Example
HistoryColumnChart0.AddNewLimitLine("Var.Variable0",0,Colors.Red,5)
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
HistoryColumnChart0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
Print
Print
Define
Print()
Example
Print the history histogram controls
VBScript Example
Call HistoryColumnChart0.Print()
Query
Query history data
Define
Query()
Example
Query history data
Note : when the history is timing record,The query rules should be set up in the toolbar before querying
data.
VBScript Example
Call
HistoryColumnChart0.SetDateConditionListStartEndTime(DateTimePicker0.ValueTime
Call HistoryColumnChart0.Query()
Save
Save
Define
Save()
Example
Save the history histogram controls
VBScript Example
Call HistoryColumnChart0.Save()
SetDateConditionListStartEndTime
Set the start and end times
Define
SetDateConditionListStartEndTime(startTime , endTime)
Parameter
Name Required/Optional Data Type Description
startTime Required DateTime Start time
endTime Required DateTime End time
Example
Set the start and end times
VBScript Example
Call
HistoryColumnChart0.SetDateConditionListStartEndTime(DateTimePicker0.ValueTime
SetSeriesVariablePath
Replace the variables associated with the curve
Define
SetSeriesVariablePath(pathList)
Parameter
Data
Name Required/Optional Description
type
The name of the new variable to be replaced in turn,separated
pathList Required String
by comma
Example
Replace the variables associated with the curve
VBScript Example
Call
HistoryColumnChart0.SetSeriesVariablePath("Var.HColumn.Variable,Var.HColumn.Va
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
HistoryColumnChart0.Height = 100
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
HistoryColumnChart0.IsShow = True
HistoryColumnChart0.IsShow = False
Left
The left coordinate
Define
Double Left
Example Object's left side of the coordinate values is 100 on the
screen
VBScript Example
HistoryColumnChart0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = HistoryColumnChart0.Name
NumberAxisMaximum
Get or set the maximum of the number axis
Define
Double NumberAxisMaximum
Example Set the maximum value of number axis to120
VBScript Example
HistoryColumnChart0.NumberAxisMaximum = 120
NumberAxisMinimum
Get or set the minimum of the number axis
Define
Double NumberAxisMinimum
Example Set the minimum value of number axis to 20
VBScript Example
HistoryColumnChart0.NumberAxisMinimum = 20
NumberInterval
The large scale of number axis(The interval between two adjacent
large scale lines)
Define
Double NumberInterval
Example Set the large scale of number axis to 20
VBScript Example
HistoryColumnChart0.NumberInterval = 20
NumberSmallInterval
The small scale of number axis(The number of small scale lines
between two adjacent large scale lines.)
Define
Double NumberSmallInterval
Example Set the small scale of number axis to 4
VBScript Example
HistoryColumnChart0.NumberSmallInterval = 4
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
HistoryColumnChart0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
HistoryColumnChart0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
HistoryColumnChart0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example
Set the Zindex of the specified object to 3
VBScript Example
HistoryColumnChart0.ZIndex = 3
HMIRecordBox
Record box control
Methods list
Name Description
DataExport Export all the data
Look for animation to modify the
FindAnimation associated variables of the
animation
Print Print
QueryHistoryDate The inquiry of historical record
The inquiry of historical record
QueryHistoryWithType
with type
Save Save
Property list
Name Description
Height Height
Whether display the
IsShow
specified object or not
Whether to show the print
IsShowBtnPrint
button
Whether to show the save
IsShowBtnSave
button
Whether to show the
IsShowRdBtnConfig
setting button of column
Whether to show the
IsShowRdBtnUpdate
query button
Whether to show the
IsShowRdCbTime Quick QueryTimeSet
button
Whether to show the
IsShowRdRecordSelectedType RecordSelectedType
button
Whether to show the
IsShowRdRtExport
export button
IsShowRdSetTime Whether to show the
QueryTimeSet button
Left The left coordinate
Name Name
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
DataExport
Export all the data
Define
DataExport(isAllExport)
Parameter
Data
Name Required/Optional Description
Type
Whether to export all
the data(true:export all
isAllExport Required Boolean
the data,false:export
the current page)
Example
Export all the data
VBScript Example
RecordBox0.DataExport(True)
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
RecordBox0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
Print
Print
Define
Print()
Example
Print the record box
VBScript Example
RecordBox0.Print()
QueryHistoryDate
The inquiry of historical record
Define
QueryHistoryDate(StartTime ,EndTime)
Parameter
Name Required/Optional Data Type Description
StartTime Required DateTime Start time
EndTime Required DateTime End time
Example
Query the data within the specified time period
VBScript Example
Call
RecordBox0.QueryHistoryDate(DateTimePicker0.ValueTime,DateTimePicker1.ValueTim
QueryHistoryWithType
The inquiry of historical record with type
Define
QueryHistoryDate(StartTime ,EndTime,type)
Parameter
Name Required/Optional Data Type Description
StartTime Required DateTime Start time
EndTime Required DateTime End time
Type Required Int Type
Example
Query the data within the specified time period with type
VBScript Example
Call
RecordBox0.QueryHistoryWithType(DateTimePicker0.ValueTime,DateTimePicker1.Valu
Save
Save
Define
Save()
Example
Save the record box
VBScript Example
RecordBox0.Save()
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
RecordBox.Height = 100
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
RecordBox0.IsShowBtnPrint = true
IsShowBtnSave
Show the Save Button
Define
Boolean IsShowBtnSave
Example
Whether the record box control to show the Save Button
VBScript Example
RecordBox0.IsShowBtnSave = true
IsShowRdBtnConfig
Show the Column Setting button
Define
Boolean IsShowRdBtnConfig
Example
Whether the record box control to show the Column Setting button
VBScript Example
RecordBox0.IsShowRdBtnConfig = true
IsShowRdBtnUpdate
Show the query button
Define
Boolean IsShowRdBtnUpdate
Example
Whether the record box control to show the query button
VBScript Example
RecordBox0.IsShowRdBtnUpdate = true
IsShowRdCbTime
Show the QuickQueryTimeSet button
Define
Boolean IsShowRdCbTime
Example
Whether the record box control to show the QuickQueryTimeSet
button
VBScript Example
RecordBox0.IsShowRdCbTime = true
IsShowRdRecordSelectedType
Show the RecordSelectedType button
Define
Boolean IsShowRdRecordSelectedType
Example
Whether the record box control to show the RecordSelectedType
button
VBScript Example
RecordBox0.IsShowRdRecordSelectedType = true
IsShowRdRtExport
Show the export button
Define
Boolean IsShowRdRtExport
Example
Whether the record box to show the export button
VBScript Example
RecordBox0.IsShowRdRtExport = true
IsShowRdSetTime
Show the QueryTimeSet button
Define
Boolean IsShowRdSetTime
Example
Whether the record box control to show the QueryTimeSet button
VBScript Example
RecordBox0.IsShowRdSetTime = true
Left
The left coordinate
Define
Double Left
Example Object's left side of the coordinate values is 100 on the
screen
VBScript Example
RecordBox0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = RecordBox0.Name
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
RecordBox0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
RecordBox0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
RecordBox0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example
Set the Zindex of the specified object to 3
VBScript Example
RecordBox0.ZIndex = 3
HMIAlarmWindow
Alarm window control
Methods list
Name Description
Reply to the selected
AckAlarm
alarm
Reply all the alarm that
AckAllAlarm
record type is alarm
Reply all the alarm that
AckAllRecovery
record type is recover
DataExport Export the data
Look for animation to
FindAnimation modify the associated
variables of the animation
Get the content of the
GetCurrentAlarmColumnInf currently selected alarm
column
Get the data table of the
GetHistoryAlarmItemDataTable
historical data
Get the current number of
GetRowNum
real-time alarm Windows
Print Print
The query of the historical
QueryHistoryAlarm
alarm
Save Save
Set the currently selected
SetCurrentSelectRowIndex
item
Set the parameters of the
SetExportValue
alarm data export script
Start loading the real-time
StartRealTimeAlarm
alarm data
Stop loading the real-time
StopRealTimeAlarm
alarm data
Property list
Name Description
Height Height
Whether display the specified
IsShow
object or not
Whether to show the header of the
IsShowHistoryTabItem
history alarm
Whether to show the header of the
IsShowRelTableItem
real-time alarm
Left The left coordinate
Name Name
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
AckAlarm
Reply to a selected alarm
Define
AckAlarm()
Example Reply to a selected alarm
VBScript Example
Call AlarmWindow0.AckAlarm()
AckAllAlarm
Reply all the alarm that record type is alarm
Define
AckAllAlarm()
Example
Reply all the alarm that record type is alarm
VBScript Example
Call AlarmWindow0.AckAllAlarm()
AckAllRecovery
Reply all the alarm that record type is recover
Define
AckAllRecovery()
Example
Reply all the alarm that record type is recover
VBScript Example
Call AlarmWindow0.AckAllRecovery()
DataExport
Export data
Define
DataExport()
Example
Export data
VBScript Example
Call AlarmWindow0.SetExportValue(False,True)
Call AlarmWindow0.DataExport()
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
AlarmWindow0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
GetCurrentAlarmColumnInf
Get the content of the currently selected alarm column
Define
GetCurrentAlarmColumnInf(columnlndex)
Parameter
Data
Name Required/Optional Description
Type
Column index (value
columnlndex Required Int
range: 0~14)
Example
Get the content of the currently selected alarm column
VBScript Example
Text0.Text =
AlarmWindow0.GetCurrentAlarmColumnInf(5)
GetHistoryAlarmItemDataTable
Get the data table of the historical data
Define
GetHistoryAlarmItemDataTable(beginTime , endTime)
Parameter
Data
Name Required/Optional Description
Type
beginTime Required DateTime The begin time
endTime Required DateTime The end time
Example
Get the data table of the historical data
VBScript Example
dt =
AlarmWindow0.GetHistoryAlarmItemDataTable(DateTimePicker0.ValueTime,DateTimePi
Call ReportCmd.DirectExportDataToExcel(dt,"D:\Test_Alarm.xlsx",1)
GetRowNum
Get the current number of real-time alarm Windows
Define
GetRowNum(variablePath)
Parameter
Data
Name Required/Optional Description
Type
Variable path,Assign the
variablePath Required Int returned value to this
variable
Example
Get the current number of real-time alarm Windows, and pass the
returned value to the parameter "var.variable 0"
VBScript Example
Call AlarmWindow0.GetRowNum("Var.Variable0")
Print
Print
Define
Print()
Example Print
VBScript Example
Call AlarmWindow0.Print()
QueryHistoryAlarm
The inquiry of historical data
Define
QueryHistoryAlarm(startTime , endTime)
Parameter
Data
Name Required/Optional Description
Type
startTime Required DateTime The query of the start time
endTime Required DateTime The query of the end time
Example
The inquiry of historical alarm
VBScript Example
Call
AlarmWindow0.QueryHistoryAlarm(DateTimePicker0.ValueTime,DateTimePicker1.Value
Save
Save
Define
Save()
Example Save
VBScript Example
Call AlarmWindow0.Save()
SetCurrentSelectRowIndex
Set the currently selected item
Define
SetCurrentSelectRowIndex(selectlndex)
Parameter
Data
Name Required/Optional Description
Type
selectlndex Required Int Select row index
Example
Select the third row and get the contents of column 5 of that row
VBScript Example
Call AlarmWindow0.SetCurrentSelectRowIndex(3)
Text0.Text =
AlarmWindow0.GetCurrentAlarmColumnInf(5)
SetExportValue
Set the parameters of the alarm data export script
Define
SetExportValue(isReal , isExportAll)
Parameter
Data
Name Required/Optional Description
Type
Whether it is a real - time
isReal Required Bool
alarm
isExportAll Required Bool Whether to export all report
Example
Export real-time alarm
VBScript Example
Call AlarmWindow0.SetExportValue(True,True)
Call AlarmWindow0.DataExport()
StartRealTimeAlarm
Start loading the real-time alarm data
Define
StartRealTimeAlarm()
Example
Start loading the real-time alarm data
VBScript Example
Call AlarmWindow0.StartRealTimeAlarm()
StopRealTimeAlarm
Stop loading the real-time alarm data
Define
StopRealTimeAlarm()
Example
Stop loading the real-time alarm data
VBScript Example
Call AlarmWindow0.StopRealTimeAlarm()
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
AlarmWindow0.Height = 100
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
AlarmWindow0.IsShowHistoryTabItem = True
IsShowRelTableItem
Whether to show the header of the real-time alarm
Define
Boolean IsShowRelTableItem
Example
Set to show the header of the real-time alarm
VBScript Example
AlarmWindow0.IsShowRelTableItem = True
Left
The left coordinate
Define
Double Left
Example Object's left side of the coordinate values is 100 on the
screen
VBScript Example
AlarmWindow0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = AlarmWindow0.Name
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
AlarmWindow0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
AlarmWindow0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
AlarmWindow0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example
Set the Zindex of the specified object to 3
VBScript Example
AlarmWindow0.ZIndex = 3
HMIScrollAlarm
Scroll alarm control
Methods list
Name Description
Look for animation to modify the
FindAnimation associated variables of the
animation
Start loading the real-time alarm
StartRealTimeAlarm
data
StopRealTimeAlarm Stop loading the real-time alarm data
Property list
Name Description
Height Height
Whether display the specified object or
IsShow
not
Left The left coordinate
Name Name
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
ScrollAlarm0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
StartRealTimeAlarm
Start loading the real-time alarm data
Define
StartRealTimeAlarm()
Example
Start loading the real-time alarm data
VBScript Example
Call ScrollAlarm0.StartRealTimeAlarm()
StopRealTimeAlarm
Stop loading the real-time alarm data
Define
StopRealTimeAlarm()
Example
Stop loading the real-time alarm data
VBScript Example
Call ScrollAlarm0.StopRealTimeAlarm()
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
ScrollAlarm0.Height = 100
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
ScrollAlarm0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = ScrollAlarm0.Name
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
ScrollAlarm0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
ScrollAlarm0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
ScrollAlarm0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example
Set the Zindex of the specified object to 3
VBScript Example
ScrollAlarm0.ZIndex = 3
HMIReport
Report control
Methods list
Name Description
Add real-time
AddRealTimeSubReport refresh of
subreport
The table cell is
CellBindingToVariable bound to the
variable
Repace template
ChangeVariablePath
variables
Empty the entire
ClearCellContent contents of the
report cell
Empty the entire
contents of the
ClearCellContentForSheet
specified
worksheet
Clear historical
ClearSubReportHisData
data of subreport
Export the
general
ExportDataToXls data(Excel file or
report forms
template)
Export the
ExportDataToXlsByDialog general data(Pop-
up the dialog box)
Export subreport
ExportSubReport
data
Export the data of
ExportToXls the time interval
to the template
ExportToXlsForDataTable Export the
specified data
table to the excel
forms
Query the save
ExportToXlsPagesDlg dialog box of the
sectional data
Look for
animation to
modify the
FindAnimation
associated
variables of the
animation
To obtain the
GetCellValue
value of the cell
Get the
statement's
GetCurrentRowValue content of the
column specified
by the current line
Statistical
GetDataColumnStaticsValue calculations to the
Data Table
To obtain the Data
Table for the
GetDataTableExcludeHistoryData
query of the
historical data
Get the Data
Table of the data
GetDataTableFromReport
source from the
report
Get the report
template
GetProjectReportTemplates sequence from
the current
directory
GetQueryHistoryData Get the data of a
specified period
and import it to
the Data Table
Get data from the
table, and the
GetQueryHIstoryGroupData
name of the table
is specified
Write the Data
GetReportDataTable Table to the
database
Hide the columns
HiddenReportColumns
of the query
Import file to
ImportDataToControl
report
Pop-up dialog to
ImportDataToControlByDialog
import files
Open the current
OpenDataTemplate
report template
Open the
OpenDataTemplate specified report
template
Print Print
Print the paged
PrintTemplate
data
To obtain the path
ProjectDirectory
of the project
Query the alarm
QueryAlarmData
data
External database
QueryDataFromExtern
report queries
Query results
according to the
QueryHistoryData
setting time
interval
QueryHistoryDataByCommon Query of the
general historical
data
QueryHistoryDataForSheet Worksheet query
Query historical
QuerySubReportHisData
data of subreport
Query the system
QuerySystemEventData
event
Query records of
QueryVariableOperations the variable
operating
Registry variable
RegisterVariableToCell transfer into table
cell
Remove real-time
RemoveRealTimeSubReport refresh of
subreport
Export the real-
ReplaceCellVariableToControl time data for
replacement
Modify the
SaveReportAndOpenToCurrentTemplate opened template
and save
Setup the number
SetActiveGridColumnCount of columns of the
worksheet
Setup the number
SetActiveGridRowCount of rows of the
worksheet
Setup the active
SetActiveWorkSheet
worksheet
Setup the
SetCellBackgroundColor background color
of the table cell
Setup the font
SetCellFontColor color of the table
cell
SetCellValue Setup the content
of the table cell
Setup the name
SetColumnNames
of the column
Setup the current
SetCurrentReportTemplate template of the
report form
Setup the date
SetDateFormat
format
Setup Pdf export
SetPdfSetting method
format
Setup the starting
location of the
SetQueryDataStartPosition
data in the report
form
Whether to
remove the
SetRealTimeClearOld
content of
previous lines
Setup the main
SetRealTimeVariableChange variables of
variable alteration
Set main variable
of subreport(with
SetSubReportMainVariable
the lowest refresh
rate)
Set the name of
SetVarRecordRulerName
worksheet ruler
Setup a whole
SetWholeRowValueToCells row of data from
the start position
Setup the end
SetWorkSheetEndTime
time of query
Setup the time
SetWorkSheetIntervalTime
interval of query
SetWorkSheetStartTime Setup the start
time of query
Set the worksheet
SetWorkSheetTotalIntervalTime time interval into
the dictionary
The Data Table is
displayed in the
ShowDataTableForReport
report form
controls
Start to update
StartSubReportRT real-time data of
the subreport
The real-time data
StartUpdateDataFromRT
start updating
Stop the changes
StopRealTimeVariableChange of the real-time
variable
Remove all the
binding which
StopRegisterVaraibleChange
variables convert
into table cell
Stop to update
StopSubReportRT the real-time data
of the subreport
Set the query time
ascending and
TriggerTimeOrder
descending order
sorting
Unbound the
UnBindingEventChange table cell change
events
Unbundle
UnRegisterVariableToCell variables convert
into table cell
VisiableReportColumns Show the
columns of the
query
Property list
Name Description
Height Height
Get or setup the number of days that
IntervalDay
query data interval
Get or setup the number of hours that
IntervalHour
query data interval
Get or setup the number of
IntervalMillisecond
milliseconds that query data interval
Get or setup the number of minutes
IntervalMinute
that query data interval
Get or setup the number of months
IntervalMonth
that query data interval
Get or setup the number of quarters
IntervalQuarter
that query data interval
Get or setup the number of seconds
IntervalSecond
that query data interval
IntervalUnit Unit of time interval
Get or setup the number of years that
IntervalYear
query data interval
Whether display the specified object or
IsShow
not
Left The left coordinate
Name Name
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
AddRealTimeSubReport
Add real-time refresh of subreport
Define
AddRealTimeSubReport(subReportName , mode)
Parameter
Data
Name Required/Optional Description
Type
subReportName Required String The name of subreport
1 means that the variable is updated in the
mode Required Int increasing number of rows, otherwise it is
updated in the specified cell
Example The real-time variables bound to subreport0 start to update. The data is
displayed in the increasing number of rows, and the number of refreshed rows is 20
VBScript Example
Call Report0.StartSubReportRT()
Call Report0.AddRealTimeSubReport("SubReport0",1)
Call
Report0.SetSubReportMainVariable("SubReport0","Var.Variable",20)'Set
main variable
CellBindingToVariable
The table cell is bound to the variable
Define
CellBindingToVariable(sheetIndex , rowIndex , columnIndex ,
variablePath)
Parameter
Data
Name Required/Optional Description
Type
sheetIndex Required Int The worksheet index
rowIndex Required Int The row num ber
columnIndex Required Int The column number
variablePath Required String The variable path
For i = 1 To 10
Call
Report0.CellBindingToVariable(0,i,6,"Var.Variable"&i)
Next
Related script :
Unbound the table cell change events
VBScript Example
Call Report0.UnBindingEventChange(0)
ChangeVariablePath
Repace variables of report template
Define
ChangeVariablePath(rowIndex , columnIndex , variablePath)
Parameter
Data
Name Required/Optional Description
Type
rowIndex Required Int The row num ber
columnIndex Required Int The column number
variablePath Required String The variable path
Call
Report0.ChangeVariablePath(2,2,"VarRecord.RecordVariable")
ClearCellContent
Empty the entire contents of the report cell (In the case of unbound
report template, all contents of the report cell can be emptied; In the
case of binding, it is equivalent to re-opening the report template.)
Define
ClearCellContent()
Example
Empty the entire contents of the report cell
VBScript Example
Call Report0.ClearCellContent()
ClearCellContentForSheet
Empty the entire contents of the specified worksheet
Define
ClearCellContentForSheet(sheetIndex)
Parameter
Data
Name Required/Optional Description
Type
sheetIndex Required Int The worksheet index
Call Report0.ClearCellContentForSheet(0)
ClearSubReportHisData
Clear historical data of subreport
Define
ClearSubReportHisData(subReportName)
Parameter
Data
Name Required/Optional Description
Type
subReportName Required String The name of subreport
Call Report0.ClearSubReportHisData("SubReport0")
ExportDataToXls
Export the general data(All data can be exported except toolbar
data queries and script data queries of "QueryHistoryData" and
"QueryHistoryDataForSheet")
Define
ExportDataToXls(filePath)
Parameter
Data
Name Required/Optional Description
Type
filePath Required String Absolute path
Example
Export the general data
VBScript Example
Call Report0.ExportDataToXls("D:\test.xls")
ExportDataToXlsByDialog
Export the general data(All data can be exported except toolbar
data queries and script data queries of "QueryHistoryData" and
"QueryHistoryDataForSheet")
Define
ExportDataToXlsByDialog()
Example
Export the general data
VBScript Example
Call Report0.ExportDataToXlsByDialog()
ExportSubReport
Export subreport data
Define
ExportSubReport(filePath)
Parameter
Data
Name Required/Optional Description
Type
filePath Required String Save path of file
call Report0.ExportSubReport("D:\test1.xls")
ExportToXls
Export the data of the time interval to the template,Use pagination to query
(suggest using this method to export, export faster)
Define
ExportToXls(excelfilePath)
Parameter
Data
Name Required/Optional Description
Type
excelfilePath Required String Absolute path
Example
Export the data of the time interval to the template(data query must be done
first)
VBScript Example
Call Report0.ExportToXls("D:\test.xls")
VBScript Example
Call
Report0.SetWorkSheetStartTime(0,DateTimePicker0.ValueTime)
Call
Report0.SetWorkSheetEndTime(0,DateTimePicker1.ValueTime)
Call Report0.SetVarRecordRulerName(0,"s1")
Call Report0.QueryHistoryData()
ExportToXlsForDataTable
Export the specified data table to the excel forms
Define
ExportToXlsForDataTable(dt , excelPath , excelVersion)
Parameter
Data
Name Required/Optional Description
Type
dt Required DataTable The data source
excelPath Required String Export the absolute path
excel version(0 stands for
excelVersion Required Int 2003,otherwise stands for
2007)
Example
1.Export the specified data table to the excel
VBScript Example
dt = DbAccess.DatabaseAccess.GetTable()
Call
ReportForms0.ExportToXlsForDataTable(dt,"D:\test.xls",1)
2.Export the DataTable from the report control to excel (This situation must
be combined with scripts such as the general historical data query,system
event query and operation variable record query)
VBScript Example
dt = ReportForms0.GetDataTableExcludeHistoryData()
Call
ReportForms0.ExportToXlsForDataTable(dt,"D:\test.xls",1)
dt = ReportForms0.GetDataTableFromReport(1)
Call
ReportForms0.ExportToXlsForDataTable(dt,"D:\test.xls",1)
ExportToXlsPagesDlg
Query the save dialog of the segmented data
Define
ExportToXlsPagesDlg()
Example
Query the save dialog of the segmented data
VBScript Example
Call Report0.ExportToXlsPagesDlg()
Call
Report0.SetWorkSheetStartTime(0,DateTimePicker0.ValueTime)
Call
Report0.SetWorkSheetEndTime(0,DateTimePicker1.ValueTime)
Call Report0.SetVarRecordRulerName(0,"s1")
Call Report0.QueryHistoryData()
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
Report0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
GetCellValue
To obtain the value of the table cell
Define
GetCellValue(rowIndex , columnIndex)
Parameter
Data
Name Required/Optional Description
Type
The number of rows,
rowIndex Required Int
starting from 1
The number of columns,
columnIndex Required Int
starting from 1
Button0.Content = Report0.GetCellValue(1,1)
GetCurrentRowValue
Get the content of the report forms specified by the current line
Define
GetCurrentRowValue(columnIndex)
Parameter
Data
Name Required/Optional Description
Type
The number of columns,
columnIndex Required Int
starting from 1
Example
Get the content of the report forms in the first column of current line
VBScript Example
Button0.Content = Report0.GetCurrentRowValue(1)
GetDataColumnStaticsValue
Statistical calculations to the Data Table
Define
GetDataColumnStaticsValue(dt , columnName , functionName)
Parameter
Data
Name Required/Optional Description
Type
dt Required DataTable The data source
columnName Required String Column names collection,seperated by commas
Function names
functionName Required String
collection(avg,min,max,sum),seperated by commas
Call Report0.SetWorkSheetStartTime(0,DateTimePicker0.ValueTime)
Call Report0.SetWorkSheetEndTime(0,DateTimePicker1.ValueTime)
Call Report0.SetVarRecordRulerName(0,"s1") 'Set the query rules for historical
data,and interval time is 1s
dt = Report0.GetQueryHistoryData(0,"VarRecord.RecordVariable","1") 'Get
data within the specified time period,and the parameter "1" means "Value"
ff =
Report0.GetDataColumnStaticsValue(dt,"VarRecord.RecordVariable","avg")
Call Report0.SetCellValue(ff,1,5) 'Displays the calculated results in the first
row and fifth column of the Report control
Call Report0.SetWorkSheetStartTime(0,DateTimePicker0.ValueTime)
Call Report0.SetWorkSheetEndTime(0,DateTimePicker1.ValueTime)
Call Report0.SetWorkSheetIntervalTime(0,1000) 'The time interval for the
history group is 1000 ms
dt = Report0.GetQueryHistoryData(0,"HistRecord.aaa.RecordVariable","1")
ff =
Report0.GetDataColumnStaticsValue(dt,"HistRecord.aaa.RecordVariable","avg")
Call Report0.SetCellValue(ff,2,5)
or
VBScript Example
Call Report0.SetWorkSheetStartTime(0,DateTimePicker0.ValueTime)
Call Report0.SetWorkSheetEndTime(0,DateTimePicker1.ValueTime)
Call Report0.SetWorkSheetIntervalTime(0,1000) 'The time interval for the
history group is 1000 ms
dt = Report0.GetQueryHistoryData(0,"HistRecord.aaa.RecordVariable","1")
ff = Report0.GetDataColumnStaticsValue(dt,"1","avg") 'The "1" represents the
index of the historical variable and begins with "1".
Call Report0.SetCellValue(ff,2,5)
dt = DbAccess.DatabaseAccess.GetTable()
ff = Report0.GetDataColumnStaticsValue(dt,"age","avg")
Call Report0.SetCellValue(ff,3,5)
GetDataTableExcludeHistoryData
To obtain the Data Table for the query of the historical data(This
script must be combined with those scripts such as the general
historical data query,system event query and operation variable
record query)
Define
GetDataTableExcludeHistoryData()
Example
To obtain the Data Table for the query of the historical data
VBScript Example
dt = Report0.GetDataTableExcludeHistoryData()
Call
Report0.ExportToXlsForDataTable(dt,"D:\test.xls",1)
'the parameter "1" means "excel version"("0" is 2003,otherwise
2007)
GetDataTableFromReport
Get the Data Table of the data source from the report (The contents
of the report display)
Define
GetDataTableFromReport(model)
Parameter
Data
Name Required/Optional Description
Type
0 means have no column
model Required Int name,otherwise have a column
name
Example
Get the Data Table of the data source from the report
VBScript Example
dt = Report0.GetDataTableFromReport(1)
Call
Report0.ExportToXlsForDataTable(dt,"D:\test.xls",1)
GetProjectReportTemplates
Get the report template sequence from the current directory
Define
GetProjectReportTemplates()
Example
Get the report template sequence from the current directory
VBScript Example
Text0.Text = Report0.GetProjectReportTemplates()
GetQueryHistoryData
Get the data of a specified period and import it to the Data Table
Define
GetQueryHistoryData(sheetIndex , conditions , types)
Parameter
Data
Name Required/Optional Description
Type
sheetIndex Required Int The worksheep index
conditions Required String Conditions is the variable collection, separated by commas
Types are divided into TriggeringTime、Value, which can
types Required String
use 0 and 1 instead
Example 1. Get the "Variable record (Timing record)" data to the DataTable within a specified time, and
display in the Report control
VBScript Example
Call Report0.SetWorkSheetStartTime(0,DateTimePicker0.ValueTime)
Call Report0.SetWorkSheetEndTime(0,DateTimePicker1.ValueTime)
Call Report0.SetVarRecordRulerName(0,"s1")
dt =
Report0.GetQueryHistoryData(0,"VarRecord.RecordVariable,VarRecord.RecordVariab
Call Report0.ShowDataTableForReport(1,1,dt)
2.Get the "Variable group record" data in the specified time to the DataTable, and display in the Report
control
VBScript Example
Call Report0.SetWorkSheetStartTime(0,DateTimePicker0.ValueTime)
Call Report0.SetWorkSheetEndTime(0,DateTimePicker1.ValueTime)
Call Report0.SetWorkSheetIntervalTime(0,1000)
dt = Report0.GetQueryHistoryData(0,"HistRecord.aaa.RecordVariable","1")
Call Report0.ShowDataTableForReport(1,1,dt)
GetQueryHistoryGroupData
Get data from the table, and the name of the table is specified
Define
GetQueryHistoryGroupData(sheetIndex , tableName , columnNames , rowCount)
Parameter
Data
Name Required/Optional Description
Type
sheetIndex Required Int The worksheep index
tableName Required String The name of the historical variables group
columnNames Required String Historical variables collection,separated by commas
rowCount Required Int The number of rows
Example
Get data from the table, and the name of the table is specified
VBScript Example
Call Report0.SetWorkSheetStartTime(0,DateTimePicker0.ValueTime)
Call Report0.SetWorkSheetEndTime(0,DateTimePicker1.ValueTime)
Call Report0.SetWorkSheetIntervalTime(0,1000)
dt =
Report0.GetQueryHistoryGroupData(0,"aaa","HistRecord.aaa.RecordVariable,HistRe
Call Report0.ShowDataTableForReport(1,1,dt)
GetReportDataTable
Write the Data Table to the database
Define
GetReportDataTable(mainKey)
Parameter
Data
Name Required/Optional Description
Type
Specify which column as the
mainKey Required Int
primary key
Example
The report shows the data in the database access table, manually
modify the data in the table, and then use this script to save to the
database
VBScript Example
dt = Report0.GetReportDataTable(0)
cc = DbAccess.DatabaseAccess.SaveTable(dt)
dt = DbAccess.DatabaseAccess.GetTable()
Call Report0.ShowDataTableForReport(1,1,dt)
HiddenReportColumns
Hide the columns of the query
Define
HiddenReportColumns(columns)
Parameter
Data
Name Required/Optional Description
Type
columns Required String The number of columns
Example
Hide the columns of the query
VBScript Example
Call Report0.HiddenReportColumns("Alarm")
Call Report0.VisiableReportColumns("Alarm")
ImportDataToControl
Import file to report
Define
ImportDataToControl(filePath)
Parameter
Data
Name Required/Optional Description
Type
filePath Required String The path of file
Example
Import file to report
VBScript Example
Call Report0.ImportDataToControl("D:\test.xls")
ImportDataToControlByDialog
Pop-up dialog to import files
Define
ImportDataToControlByDialog()
Example
Pop-up dialog to import files
VBScript Example
Call Report0.ImportDataToControlByDialog()
OpenDataTemplate
Open the current report template
Define
OpenDataTemplate()
Example
Open the current template
VBScript Example
Call Report0.OpenDataTemplate()
OpenDataTemplate
Open the template specified worksheet
Define
OpenDataTemplate(sheetIndex , templatePath)
Parameter
Data
Name Required/Optional Description
Type
sheetIndex Required String The worksheep index
The name of the report
templatePath Required String
template
Example
Open the template specified worksheet
VBScript Example
Call Report0.OpenDataTemplate(0,"Report0")
Print
Print
Define
Print()
Example Print
VBScript Example
Call Report0.Print()
PrintTemplate
Print the paged data
Define
PrintTemplate()
Example
Print the paged data
VBScript Example
Call Report0.PrintTemplate()
Related scripts:
VBScript Example
Call
Report0.SetWorkSheetStartTime(0,DateTimePicker0.ValueTime)
Call
Report0.SetWorkSheetEndTime(0,DateTimePicker1.ValueTime)
Call Report0.SetVarRecordRulerName(0,"s1")
Call Report0.QueryHistoryData()
ProjectDirectory
To obtain the path of the project
Define
ProjectDirectory()
Example
To obtain the path of the project
VBScript Example
Text0.Text = Report0.ProjectDirectory()
QueryAlarmData
Query the alarm data
Define
QueryAlarmData(sheetIndex)
Parameter
Data
Name Required/Optional Description
Type
The worksheep index,starting from
sheetIndex Required Int
0
Example
Query the alarm data
VBScript Example
Call
Report0.SetWorkSheetStartTime(0,DateTimePicker0.ValueTime)
Call
Report0.SetWorkSheetEndTime(0,DateTimePicker1.ValueTime)
Call Report0.QueryAlarmData(0)
QueryDataFromExtern
Query the external database report forms
Define
QueryDataFromExtern(sheetIndex , dt)
Parameter
Data
Name Required/Optional Description
Type
The worksheep index,
sheetIndex Required Int
starting from 0
dt Required DataTable The data source
Example
Query the external database report forms ( Operation method:1.
Create a report template for the external database 2. Bind to the
report control 3. Execute the query script)
VBScript Example
dt = DbAccess.DatabaseAccess.GetTable()
Call Report0.QueryDataFromExtern(0,dt)
QueryHistoryData
Query results according to the setting time interval
Define
QueryHistoryData()
Example
1. According to the rule "s1" query timing "variable record" (the report control
must be associated with the historical report template)
VBScript Example
Call
Report0.SetWorkSheetStartTime(0,DateTimePicker0.ValueTime)
Call
Report0.SetWorkSheetEndTime(0,DateTimePicker1.ValueTime)
Call Report0.SetVarRecordRulerName(0,"s1")
Call Report0.QueryHistoryData()
2. Query "variable group record" according to the interval time of 1000ms (the
report control must be associated with historical group report template)
VBScript Example
Call
Report0.SetWorkSheetStartTime(0,DateTimePicker0.ValueTime)
Call
Report0.SetWorkSheetEndTime(0,DateTimePicker1.ValueTime)
Call Report0.SetWorkSheetIntervalTime(0,1000)
Call Report0.QueryHistoryData()
QueryHistoryDataByCommon
Query of the general historical data
Define
QueryHistoryDataByCommon(sheetIndex , conditions , types)
Parameter
Data
Name Required/Optional Description
Type
sheetIndex Required Int The worksheep index
conditions Required String The condition is the variable set, separated by commas
Types are divided into TriggeringTime and Value,which can
types Required String
be replace by 0 and 1
Example
1.Query variable records (Timing records)
VBScript Example
Call Report0.SetWorkSheetStartTime(0,DateTimePicker0.ValueTime)
Call Report0.SetWorkSheetEndTime(0,DateTimePicker1.ValueTime)
Call Report0.SetVarRecordRulerName(0,"s1")
Call
Report0.QueryHistoryDataByCommon(0,"VarRecord.RecordVariable,VarRecord.RecordV
Call Report0.SetWorkSheetStartTime(0,DateTimePicker0.ValueTime)
Call Report0.SetWorkSheetEndTime(0,DateTimePicker1.ValueTime)
Call Report0.SetWorkSheetIntervalTime(0,1000)
Call
Report0.QueryHistoryDataByCommon(0,"HistRecord.aaa.RecordVariable,HistRecord.a
QueryHistoryDataForSheet
Query the specified worksheet, and need to associate the corresponding
report template
Define
QueryHistoryDataForSheet()
Example 1.Query the "variable record" of the timing (the report control must
be associated with the historical report template)
VBScript Example
Call
Report0.SetWorkSheetStartTime(0,DateTimePicker0.ValueTime)
Call Report0.SetWorkSheetEndTime(0,
DateTimePicker1.ValueTime)
Call Report0.SetVarRecordRulerName(0,"s1")
Call Report0.QueryHistoryDataForSheet()
Call
Report0.SetWorkSheetStartTime(0,DateTimePicker0.ValueTime)
Call Report0.SetWorkSheetEndTime(0,
DateTimePicker1.ValueTime)
Call Report0.SetWorkSheetIntervalTime(0,1000)
Call Report0.QueryHistoryDataForSheet()
QuerySubReportHisData
Query historical data of sub report
Define
QuerySubReportHisData(subReportName)
Parameter
Data
Name Required/Optional Description
Type
subReportName Required Int The name of subreport
Example
Query historical data of SubReport0
VBScript Example
Call
Report0.SetWorkSheetStartTime(0,DateTimePicker0.ValueTime)
Call
Report0.SetWorkSheetEndTime(0,DateTimePicker1.ValueTime)
Call Report0.SetVarRecordRulerName(0,"s1")
Call Report0.QuerySubReportHisData("SubReport0")
QuerySystemEventData
Query system event
Define
QuerySystemEventData(sheetIndex)
Parameter
Data
Name Required/Optional Description
Type
sheetIndex Required Int The worksheet index,start from zero
Example
Query system event
VBScript Example
Call
Report0.SetWorkSheetStartTime(0,DateTimePicker0.ValueTime)
Call
Report0.SetWorkSheetEndTime(0,DateTimePicker1.ValueTime)
Call Report0.QuerySystemEventData(0)
QueryVariableOperations
Query records of the variable operating
Define
QueryVariableOperations(sheetIndex , opVariablePaths)
Parameter
Data
Name Required/Optional Description
Type
sheetIndex Required Int The worksheet index,start from zero
The path collection of the operation variable
(null means all,"Operation"is the root
opVariablePaths Required String
node,"Operation.OperatingVariablesGroup0"
is the query of group
Example
1.Query the variable operating records (Query the root node)
VBScript Example
Call Report0.SetWorkSheetStartTime(0,DateTimePicker0.ValueTime)
Call Report0.SetWorkSheetEndTime(0,DateTimePicker1.ValueTime)
Call Report0.QueryVariableOperations(0,"Operation")
Data
Name Required/Optional Description
Type
variablePath Required String The variable path
The number of the rows,
rowIndex Required Int
starting from 1
The number of the columns,
columnIndex Required Int
starting from 1
Example
1. Register "Var. Variable0" to cell (1,1)
VBScript Example
Call Report0.SetActiveWorkSheet(1)
For i = 1 To 10
Call
Report0.RegisterVariableToCell("Var.Variable"&i,3,i)
Next
Related scripts:
a. All unbind of variable to cell
VBScript Example
Call Report0.StopRegisterVaraibleChange()
Call
Report0.UnRegisterVariableToCell("Var.Variable0",1,1)
RemoveRealTimeSubReport
Remove real-time refresh of subreport
Define
RemoveRealTimeSubReport(subReportName)
Parameter
Data
Name Required/Optional Description
Type
subReportName Required String The name of subreport
Call Report0.RemoveRealTimeSubReport("SubReport0")
ReplaceCellVariableToControl
Replace real-time report data (refresh real-time data, perform a
refresh once)
Define
ReplaceCellVariableToControl()
Example
Replace real-time report data
VBScript Example
Call Report0.ReplaceCellVariableToControl()
SaveReportAndOpenToCurrentTemplate
Modify the opened template and save
Define
SaveReportAndOpenToCurrentTemplate()
Example
Modify the opened template and save
VBScript Example
Call Report0.SaveReportAndOpenToCurrentTemplate()
SetActiveGridColumnCount
Setup the number of columns of the worksheet
Define
SetActiveGridColumnCount(columnCount)
Parameter
Data
Name Required/Optional Description
Type
columnCount Required Int The number of columns
Example
Setup the number of columns of the worksheet to 30
VBScript Example
Call Report0.SetActiveGridColumnCount(30)
SetActiveGridRowCount
Setup the number of rows of the worksheet
Define
SetActiveGridRowCount(rowCount)
Parameter
Data
Name Required/Optional Description
Type
rowCount Required Int The number of rows
Example
Setup the number of rows of the worksheet to 100
VBScript Example
Call Report0.SetActiveGridRowCount(100)
SetActiveWorkSheet
Setup the active worksheet
Define
SetActiveWorkSheet(sheetIndex)
Parameter
Data
Name Required/Optional Description
Type
The worksheet index,start
sheetIndex Required Int
from 0
Example
Setup the active worksheet
VBScript Example
Call Report0.SetActiveWorkSheet(1)
Call
Report0.SetCellBackgroundColor(1,1,Colors.Red)
SetCellBackgroundColor
Setup the background color of the table cell
Define
SetCellBackgroundColor(rowIndex , columnIndex ,
backgroundColor)
Parameter
Data
Name Required/Optional Description
Type
The number of
rowIndex Required Int
rows,start from 1
The number of
columnIndex Required Int
columns,start from 1
backgroundColor Required Brush The background color
Call
Report0.SetCellBackgroundColor(1,1,Colors.Red)
SetCellFontColor
Set the font color of the table cell
Define
SetCellFontColor(rowIndex , columnIndex , foreColor)
Parameter
Data
Name Required/Optional Description
Type
The number of rows,start
rowIndex Required Int
from 1
The number of
columnIndex Required Int
columns,start from 1
foreColor Required Brush The font color
Example Set the font color of the table cell to red(The colors
methor of the system)
VBScript Example
Call Report0.SetCellFontColor(1,1,Colors.Red)
SetCellValue
Call the script to set the value of table cells
Define
SetCellValue(value , rowIndex , columnIndex)
Parameter
Data
Name Required/Optional Description
Type
The value to set to the
value Required Object
table cells
The number of rows,start
rowIndex Required Int
from 1
The number of
columnIndex Required Int
columns,start from 1
VBScript Example
Call Report0.SetColumnNames(1,1,"SetColumnName")
SetCurrentReportTemplate
Set the current template of the report form
Define
SetCurrentReportTemplate(templateName)
Parameter
Data
Name Required/Optional Description
Type
The current template of
templateName Required String
the report form
Example
Set the current template of the report form
VBScript Example
Call
Report0.SetCurrentReportTemplate("HistoryReport")
Call Report0.OpenDataTemplate()
SetDateFormat
Set the date format
Define
SetDateFormat(format)
Parameter
Data
Name Required/Optional Description
Type
The date format(0 on behalf of
yyyy/MM/dd hh:mm:ss,1 on
behalf of yyyy-MM-dd
hh:mm:ss,2 on behalf of
format Required Int
yyyy/MM/dd,3 on behalf of
hh:mm:ss,4 on behalf of
yyyy,five digit of Taiwan format
years)
Example
Set the date format
VBScript Example
Call Report0.SetDateFormat(0)
SetPdfSetting
Setup Pdf export format
Define
SetPdfSetting(pdfColumnCount , pdfMargin , pageSize)
Parameter
Data
Name Required/Optional Description
Type
The number of
pdfColumnCount Required Int
columns
pdfMargin Required Float Page margins
Paper size, such as
pageSize Required String
A4, A5, etc
Example
Pdf export format setting
VBScript Example
Call Report0.SetPdfSetting(5,10,"A4")
SetQueryDataStartPosition
Set the starting location of the data in the report form
Define
SetQueryDataStartPosition(startRow , startColumn , _isShowColumnHeader)
Parameter
Data
Name Required/Optional Description
Type
Set the starting row of the data in the report
startRow Required Int
form,the index starting from 1
Set the starting column of the data in the report
startColumn Required Int
form,the index starting from 1
Whether to display the column header(0
_isShowColumnHeader Required Int means do not to display,greater than 0 means
to display)
Example
Set the starting location of the data in the report
VBScript Example
Call Report0.SetWorkSheetStartTime(0,DateTimePicker0.ValueTime)
Call Report0.SetWorkSheetEndTime(0,DateTimePicker1.ValueTime)
Call Report0.SetVarRecordRulerName(0,"s1")
Call Report0.SetQueryDataStartPosition(3,1,1) 'Start at row 3, column 1, and display
Call
Report0.QueryHistoryDataByCommon(0,"VarRecord.RecordVariable,VarRecord.RecordV
SetRealTimeClearOld
Whether to remove the content of previous lines
Define
SetRealTimeClearOld(_isClearOld)
Parameter
Data
Name Required/Optional Description
Type
Whether to remove(0
_isClearOld Required Int means do not to remove,1
means to remove)
Example
Do not clear the contents of previous rows for real-time data refresh
(need to associate the real-time report template)
VBScript Example
Call Report0.SetRealTimeClearOld(0)
Call Report0.StartUpdateDataFromRT(1)
Call
Report0.SetRealTimeVariableChange("Var.Variable",10)
'The number of refresh rows is 10
SetRealTimeVariableChange
Set the main variables of variable alteration
Define
SetRealTimeVariableChange(_valuePath , _totalRowCount)
Parameter
Data
Name Required/Optional Description
Type
_valuePath Required String The variable path
Set the total number of
_totalRowCount Required Int
rows
Example
Set the main variables of variable alteration
VBScript Example
Call Report0.StartUpdateDataFromRT(1)
Call
Report0.SetRealTimeVariableChange("Var.Variable0",100)
SetSubReportMainVariable
Set main variable of subreport(with the lowest refresh rate)
Define
SetSubReportMainVariable(subReportName , variablePath , totalRowCount)
Parameter
Data
Name Required/Optional Description
Type
subReportName Required String The name of subreport
variablePath Required String The main variable path
totalRowCount Required Int Tow count
Example The real-time variables bound to subreport0 start to update. The data is
displayed in the increasing number of rows, and the number of refreshed rows is 20
VBScript Example
Call Report0.StartSubReportRT()
Call Report0.AddRealTimeSubReport("SubReport0",1)
Call
Report0.SetSubReportMainVariable("SubReport0","Var.Variable",20)'Set
main variable
SetVarRecordRulerName
Set the name of the query rule
Define
SetVarRecordRulerName(RuleName)
Parameter
Data
Name Required/Optional Description
Type
The name of the timer for a
RuleName Required String
timed record
Example
Set the name of the query rule,“s1” is the timer name for the timing
record
VBScript Example
Call Report0.SetVarRecordRulerName("s1")
SetWholeRowValueToCells
Set a whole row of data from the start position
Define
SetWholeRowValueToCells(obj , startRow , startColumn)
Parameter
Data
Name Required/Optional Description
Type
obj Required String The data of rows
The number of rows,the
startRow Required Int
index starting from 1
The number of column,the
startColumn Required Int
index starting from 1
Example
Set a whole row of data from the start position
VBScript Example
Call
Report0.SetWholeRowValueToCells("30,test,5,true",1,1)
SetWorkSheetEndTime
Set the end time of query
Define
SetWorkSheetEndTime(worksheetIndex , _endTime)
Parameter
Data
Name Required/Optional Description
Type
The worksheet index,
worksheetIndex Required Int
starting from 0
_endTime Required DateTime The end time
Example
Query the data recorded by the history group (need to associate report
templates)
VBScript Example
Call
Report0.SetWorkSheetStartTime(0,DateTimePicker0.ValueTime)
Call
Report0.SetWorkSheetEndTime(0,DateTimePicker1.ValueTime)
Call Report0.SetWorkSheetIntervalTime(0,1000)
Call Report0.QueryHistoryData()
SetWorkSheetIntervalTime
Set the end time of query
Define
SetWorkSheetIntervalTime(worksheetIndex , intervalTime)
Parameter
Data
Name Required/Optional Description
Type
The worksheet index,starting
worksheetIndex Required Int
from 0
intervalTime Required Int64 The time interval,the unit is ms
Example
Query the data recorded by the history group (need to associate report
templates)
VBScript Example
Call
Report0.SetWorkSheetStartTime(0,DateTimePicker0.ValueTime)
Call
Report0.SetWorkSheetEndTime(0,DateTimePicker1.ValueTime)
Call Report0.SetWorkSheetIntervalTime(0,1000)
Call Report0.QueryHistoryData()
SetWorkSheetStartTime
Set the start time of query
Define
SetWorkSheetStartTime(worksheetIndex , _startTime)
Parameter
Data
Name Required/Optional Description
Type
The worksheet index,starting
worksheetIndex Required Int
from 0
_startTime Required DateTime The start time
Example
Query the data recorded by the history group (need to associate report
templates)
VBScript Example
Call
Report0.SetWorkSheetStartTime(0,DateTimePicker0.ValueTime)
Call
Report0.SetWorkSheetEndTime(0,DateTimePicker1.ValueTime)
Call Report0.SetWorkSheetIntervalTime(0,1000)
Call Report0.QueryHistoryData()
SetWorkSheetTotalIntervalTime
Set the worksheet time interval into the dictionary
Define
SetWorkSheetTotalIntervalTime(worksheetIndex)
Parameter
Data
Name Required/Optional Description
Type
The worksheet index,starting
worksheetIndex Required Int
from 0
Example
Set the interval time of the worksheet to the dictionary, and when the interval is
less than 0, query according to the original data in the database
VBScript Example
Call
Report0.SetWorkSheetStartTime(0,DateTimePicker0.ValueTime)
Call
Report0.SetWorkSheetEndTime(0,DateTimePicker1.ValueTime)
Report0.IntervalDay = 0
Report0.IntervalHour = 0
Report0.IntervalMinute = 0
Report0.IntervalSecond = 1
Report0.IntervalMillisecond = 0
Call Report0.SetWorkSheetTotalIntervalTime(0)
Call Report0.QueryHistoryData()
ShowDataTableForReport
The Data Table is displayed in the report form controls
Define
ShowDataTableForReport(fromRowIndex , fromColumnIndex , dt)
Parameter
Data
Name Required/Optional Description
Type
Start number of
fromRowIndex Required Int rows,the index
starting from 1
Start number of
fromColumnIndex Required Int column,the index
starting from 1
dt Required DataTable The data source
Example
The Data Table is displayed in the report form controls
VBScript Example
dt = DbAccess.DatabaseAccess.GetTable()
Call Report0.ShowDataTableForReport(1,1,dt)
StartSubReportRT
Start to update real-time data of the subreport
Define
StartSubReportRT()
Example The real-time variables bound to subreport0 start to update. The data is
displayed in the increasing number of rows, and the number of refreshed rows is 20
VBScript Example
Call Report0.StartSubReportRT()
Call Report0.AddRealTimeSubReport("SubReport0",1)
Call
Report0.SetSubReportMainVariable("SubReport0","Var.Variable",20)'Set
main variable
StartUpdateDataFromRT
The real-time data start updating
Define
StartUpdateDataFromRT(_model)
Parameter
Data
Name Required/Optional Description
Type
The value is 1 means variable
changes increasing the
_model Required Int
rows,otherwise changes in the
specified table cell
Example
1.Real-time data starts to update, and data changes in the same cell
VBScript Example
Call Report0.StartUpdateDataFromRT(0)
Related scripts:
Stop real-time variable changes
VBScript Example
Call Report0.StopRealTimeVariableChange()
StopRealTimeVariableChange
Stop the changes of the real-time variable
Define
StopRealTimeVariableChange()
Example
Stop the changes of the real-time variable
VBScript Example
Call Report0.StopRealTimeVariableChange()
StopRegisterVaraibleChange
Remove all the binding which variables convert into table cell
Define
StopRegisterVaraibleChange()
Example
Remove all the binding which variables convert into table cell
VBScript Example
Call Report0.StopRegisterVaraibleChange()
StopSubReportRT
Stop to update the real-time data of the subreport
Define
StopSubReportRT()
Example Stop real-time data refresh of all sub-reports in Report0
VBScript Example
Call Report0.StopSubReportRT()
TriggerTimeOrder
Set the query time ascending and descending order sorting
Define
TriggerTimeOrder(order)
Parameter
Data
Name Required/Optional Description
Type
0 is in ascending order and 1 is in
order Required Int
descending order
Example
Set the data for the query to be sorted in descending chronological order
VBScript Example
Call Report0.ClearCellContent()
Call
Report0.SetWorkSheetStartTime(0,Datetimepicker0.ValueTime)
Call
Report0.SetWorkSheetEndTime(0,Datetimepicker1.ValueTime)
Call Report0.SetVarRecordRulerName(0,"s1")
Call Report0.TriggerTimeOrder(1)
Call Report0.QueryHistoryData()
UnBindingEventChange
Unbound the table cell change events
Define
UnBindingEventChange(sheetIndex)
Parameter
Data
Name Required/Optional Description
Type
The worksheet
sheetIndex Required Int
index,starting from 0
Example
Unbound the table cell change events
VBScript Example
Call Report0.UnBindingEventChange(0)
UnRegisterVariableToCell
Unbundle variables convert into table cell
Define
UnRegisterVariableToCell(variablePath , rowIndex , columnIndex)
Parameter
Data
Name Required/Optional Description
Type
variablePath Required String The variable path
The number of rows,starting
rowIndex Required Int
from 1
The number of
columnIndex Required Int
columns,starting from 1
Example
Unbundle variables convert into table cell
VBScript Example
Call
Report0.UnRegisterVariableToCell("Var.Variable0",1,1)
ReportColumnsVisiable
Show the columns of the query
Define
VisiableReportColumns(columns)
Parameter
Data
Name Required/Optional Description
Type
columns Required String The number of columns
Example
Show the columns of the query
VBScript Example
Call Report0.VisiableReportColumns("Alarm")
SetColumnHidden
Unbundle variables convert into table cell
Define
SetColumnHidden( rowIndex , columnIndex,hide)
Parameter
Data
Name Required/Optional Description
Type
hide Required bool hide
rowIndex Required Int The number of rows,starting from 1
columnIndex Required Int The number of columns,starting from 1
Example
Unbundle variables convert into table cell
VBScript Example
Call
Report0.SetColumnHidden(Var.ReportCell.SrartRow,Var.ReportCell.EndRow,True)
SetRowHidden
Unbundle variables convert into table cell
Define
SetRowHidden( rowIndex , columnIndex,hide)
Parameter
Data
Name Required/Optional Description
Type
hide Required bool hide
rowIndex Required Int The number of rows,starting from 1
columnIndex Required Int The number of columns,starting from 1
Example
Unbundle variables convert into table cell
VBScript Example
Call
Report0.SetColumnHidden(Var.ReportCell.SrartRow,Var.ReportCell.EndRow,True)
FillSelectedCellRowColumnColor
Fill the selected cell row background color
Defination
FillSelectedCellRowColumnColor(RowOrColumn,fillColor)
Parameter
Name Required/Optional Datatype Description
0 is a row, otherwise
RowOrColumn required int
a column
Fill Color required Brush Color
Example
Fill line 0 with pink
VBScript Example
Call
Report0.FillSelectedCellsRowColumnColor(0,Color.Pink)
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
Report0.Height = 100
IntervalDay
Get or setup the number of days that query data interval
Define
Int64 IntervalDay
IntervalHour
Get or setup the number of hours that query data interval
Define
Int64 IntervalHour
IntervalMillisecond
Get or setup the number of milliseconds that query data interval
Define
Int64 IntervalMillisecond
IntervalMinute
Get or setup the number of minutes that query data interval
Define
Int64 IntervalMinute
IntervalMonth
Get or setup the number of months that query data interval
Define
Int64 IntervalMonth
IntervalQuarter
Get or setup the number of quarters that query data interval
Define
Int64 IntervalQuarter
IntervalSecond
Get or setup the number of seconds that query data interval
Define
Int64 IntervalSecond
IntervalUnit
Time interval unit,ms is by millisecond;ss is by second;mi is by
minute;hh is by hour;dd is by day;mm is by month;qq is by quarter;yy
is by year
Define
Int64 IntervalUnit
IntervalYear
Get or setup the number of years that query data interval
Define
Int64 IntervalYear
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
Report0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = Report0.Name
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
Report0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
Report0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
Report0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example
Set the Zindex of the specified object to 3
VBScript Example
Report0.ZIndex = 3
HMIRecipeBrowser
Recipe browser control
Methods list
Name Description
ChangeRecipeBrowser Change the recipe browser
Look for animation to modify
FindAnimation the associated variables of
the animation
Get the content of the
GetCurrentRecipeColumnInf specified column which the
row is selected
Get the recipe item name
GetRecipeItemName
which current selected
Print Print
Refresh Refresh
Save Save
SaveRecipe Save recipe
Property list
Name Description
Height Height
Whether display the specified object or
IsShow
not
IsShowStatusBar The properties of status bar
IsShowToolBar Whether to display the tool bar
Left The left coordinate
Name Name
RecipeName The name of the recipe
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
ChangeRecipeBrowser
Change the recipe browser
Define
ChangeRecipeBrowser(RecipeBrowserName)
Parameter
Data
Name Required/Optional Description
Type
The name of
RecipeBrowserName Required String
recipe
Example
Change the recipe browser
VBScript Example
RecipeBrowser0.ChangeRecipeBrowser("test")
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
RecipeBrowser0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
GetCurrentRecipeColumnInf
Get the content of the specified column which the row is selected
Define
GetCurrentRecipeColumnInf(columnName)
Parameter
Data
Name Required/Optional Description
type
columnName Required String Column name
Example
Get the content of the selected row which the column name is “water”
VBScript Example
TextBox0.Text = RecipeBrowser0.GetCurrentRecipeColumnInf("water")
GetRecipeItemName
Get the recipe item name which currently selected
Define
GetRecipeItemName()
Example
Get the recipe item name which currently selected
VBScript Example
TextBox.Text = RecipeBrowser0.GetRecipeItemName()
Print
Print
Define
Print()
Example Print
VBScript Example
RecipeBrowser0.Print()
Refresh
Refresh
Define
Refresh()
Example Refresh
VBScript Example
RecipeBrowser0.Refresh()
Save
Save
Define
Save()
Example Save
VBScript Example
RecipeBrowser0.Save()
SaveRecipe
Save recipe
Define
SaveRecipe()
Example Save recipe
VBScript Example
RecipeBrowser0.SaveRecipe()
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
RecipeBrowser0.Height = 100
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
RecipeBrowser0.IsShow = True
RecipeBrowser0.IsShow = False
IsShowStatusBar
The properties of status bar
Define
Boolean IsShowStatusBar
Example Set the recipe browser window(RecipeBrowserWindow)
to:do not display the status bar
VBScript Example
RecipeBrowser0.IsShowStatusBar = False
IsShowToolBar
Whether to display the tool bar
Define
Boolean IsShowToolBar
Example Set the recipe browser window(RecipeBrowserWindow)
to:do not display the tool bar
VBScript Example
RecipeBrowser0.IsShowToolBar = False
Left
The left coordinate
Define
Double Left
Example Object's left side of the coordinate values is 100 on the
screen
VBScript Example
RecipeBrowser0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = RecipeBrowser0.Name
RecipeName
The name of the recipe
Define
String RecipeName
Example Set the name of the recipe browser window to AAA
VBScript Example
RecipeBrowser0.RecipeName = "AAA"
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
RecipeBrowser0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
RecipeBrowser0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
RecipeBrowser0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example
Set the Zindex of the specified object to 3
VBScript Example
RecipeBrowser0.ZIndex = 3
HMIRuler
Ruler control
Methods list
Name Description
Look for animation to modify the
FindAnimation
associated variables of the animation
Print Print
Save Save
StartTimer Start timer
StopTimer Stop timer
Property list
Name Description
Height Height
Whether display the specified object or
IsShow
not
Left The left coordinate
Name Name
Textvisibility Whether to display the status column
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object
into Var.VariableGroup0.Variable1
VBScript Example
Ruler0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
Print
Print
Define
Print()
Example
Print
VBScript Example
Ruler0.Print()
Save
Save
Define
Save()
Example
Save
VBScript Example
Ruler0.Save()
StartTimer
Start timer
Define
StartTimer()
Example
Start Timer
VBScript Example
Ruler0.StartTimer()
StopTimer
Stop timer
Define
StopTimer()
Example
Stop Timer
VBScript Example
Ruler0.StopTimer()
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
Ruler0.Height = 100
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
Ruler0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = Ruler0.Name
Textvisibility
The display of the status column
Define
Boolean Textvisibility
Example
Whether to display the status column
VBScript Example
Ruler0.Textvisibility = True
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
Ruler0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
Ruler0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
Ruler0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example
Set the Zindex of the specified object to 3
VBScript Example
Ruler0.ZIndex = 3
HMICircleGauge
Dashboard control
Methods list
Name Description
Look for animation to modify the
FindAnimation
associated variables of the animation
Print Print
Save Save
StartTimer Start timer
StopTimer Stop timer
Property list
Name Description
Height Height
Whether display the specified object or
IsShow
not
Left The left coordinate
Name Name
Textvisibility Whether to display the status column
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
CircleGauge0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
Print
Print
Define
Print()
Example
Print
VBScript Example
CircleGauge0.Print()
Save
Save
Define
Save()
Example
Save
VBScript Example
CircleGauge0.Save()
StartTimer
Start timer
Define
StartTimer()
Example
Start Timer
VBScript Example
CircleGauge0.StartTimer()
StopTimer
Stop timer
Define
StopTimer()
Example
Stop Timer
VBScript Example
CircleGauge0.StopTimer()
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
CircleGauge0.Height = 100
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
CircleGauge0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = CircleGauge0.Name
Textvisibility
The display of the status column
Define
Boolean Textvisibility
Example
Whether to display the status column
VBScript Example
CircleGauge0.Textvisibility = True
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
CircleGauge0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
CircleGauge0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
CircleGauge0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example
Set the Zindex of the specified object to 3
VBScript Example
CircleGauge0.ZIndex = 3
HMIVideoMonitor
The video monitor control
Methods list
Name Description
Capture and save video or
CapturePicture
picture(select path)
Capture and save video or picture(with
CapturePicture
path)
Look for animation to modify the
FindAnimation
associated variables of the animation
Property list
Name Description
Height Height
Whether display the specified object or
IsShow
not
Left The left coordinate
Name Name
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
CapturePicture
Capture and save video or picture(select path)
Define
CapturePicture(isShowSaveFileDialog)
Parameter
Data
Name Required/Optional Description
Type
Whether it
isShowSaveFileDialog Required Bool shows the save
file dialog
Example
Capture and save video or picture
VBScript Example
Example
Capture and save video or picture
VBScript Example
Call VideoMonitor0.CapturePicture("D:\test.jpg")
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
VideoMonitor0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
VideoMonitor0.Height = 100
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
VideoMonitor0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = VideoMonitor0.Name
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
VideoMonitor0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
VideoMonitor0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
VideoMonitor0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example
Set the Zindex of the specified object to 3
VBScript Example
VideoMonitor0.ZIndex = 3
HMIWebBrowser
The web browser control
Methods list
Name Description
Look for animation to modify the
FindAnimation
associated variables of the animation
Property list
Name Description
Height Height
Home Get or set the homepage address
Whether display the specified object or
IsShow
not
Left The left coordinate
Name Name
ToolTip Tooltip text
Top The top coordinate
Url Get or set the address
Width Width
ZIndex Layer index
Default
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
WebBrowser0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
Default
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
WebBrowser0.Height = 100
Home
Get or set the homepage address
Define
Double Home
Example
Set the homepage address to Baidu
VBScript Example
WebBrowser0.Home = "https://www.baidu.com"
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
WebBrowser0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = WebBrowser0.Name
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
WebBrowser0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
WebBrowser0.Top = 100
Url
Get or set the address
Define
Double Url
Example
Set the address to Baidu
VBScript Example
WebBrowser0.Url = "https://www.baidu.com"
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
WebBrowser0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example
Set the Zindex of the specified object to 3
VBScript Example
WebBrowser0.ZIndex = 3
HMIRTSPVideoMonitor
The RTSPvideo monitor control
Methods list
Name Description
Look for animation to modify the
FindAnimation
associated variables of the animation
Property list
Name Description
Height Height
Whether display the specified object or
IsShow
not
Left The left coordinate
Name Name
ToolTip Tooltip text
Top The top coordinate
Width Width
ZIndex Layer index
Default
FindAnimation
Look for animation to modify the associated variables of the animation
Define
FindAnimation(name)
Parameter
Data
Name Required/Optional Description
type
name Required String The name of animation
Example
Change the associated variables of the visibility animation of the object into
Var.VariableGroup0.Variable1
VBScript Example
RTSPVideoMonitor0.FindAnimation("HMIShowHideAnimation").Expression
= "Var.VariableGroup0.Variable1"
Default
Height
Height
Define
Double Height
Example Set the height of the specified object to 100
VBScript Example
RTSPVideoMonitor0.Height = 100
IsShow
Whether display the specified object or not
Define
Boolean IsShow
Example True :The specified object is displayed on the screen
False :The specified object hidden on the screen
VBScript Example
RTSPVideoMonitor0.IsShow = True
RTSPVideoMonitor0.IsShow = False
Left
The left coordinate
Define
Double Left
Example Object's left side of the coordinate values is 100 on the
screen
VBScript Example
RTSPVideoMonitor0.Left = 100
Name
Name
Define
String Name
Example
Get the default name of the specified object
VBScript Example
TextBox0.Text = RTSPVideoMonitor0.Name
ToolTip
Tooltip text
Define
String ToolTip
Example Set the ToolTip of the specified object to "test"
VBScript Example
RTSPVideoMonitor0.ToolTip = "test"
Top
The top coordinate
Define
Double Top
Example Object's the top of the coordinate value is 100 in the
picture
VBScript Example
RTSPVideoMonitor0.Top = 100
Width
Width
Define
Double Width
Example Set the width of the specified object to 100
VBScript Example
RTSPVideoMonitor0.Width = 100
ZIndex
Layer index
Define
Int32 ZIndex
Example
Set the Zindex of the specified object to 3
VBScript Example
RTSPVideoMonitor0.ZIndex = 3
HMIActionCmd
Action script command
Methods list
Name Description
AnalogValueInput Analog the input action
ButtonValueInput The button input action
DiscreteValueInput The discrete value input action
StringValueInput The string input action
ToggleInput The setting input
AnalogValueInput
Analog input action
Define
AnalogValueInput(expression ,minValue ,maxValue)
Parameter
Data
Name Required/Optional Description
Type
expression Required String The variable expression
minValue Required Double The minimum value allowed to enter
maxValue Required Double The maximum value allowed to enter
Example For example,add the input action to the graphics(as shown VBScript
below),when runtime, click this graphics dialog box will pop up the analog of input
box,enter a value, click ok to assign the input values to the associated variables.
VBScript Example
ActionCmd.AnalogValueInput("Var.VariableGroup1.Variable1",0,100)
ButtonValueInput
The button input action
Define
ButtonValueInput(expression ,action ,value) action=0-Setting,1-Increase,2-
Decrease,3-Multiply,4-Divide
Parameter
Data
Name Required/Optional Description
Type
expression Required String The variable expression
The name of the action,action=0-Setting,1-
action Required Int32
Increase,2-Decrease,3-Multiply,4-Divide
value Required Double The operating value
Example
For example,add the input action to the graphics(as VBScript below),when runtime,
click this graphics dialog box will assign the input values to the associated
variables.The following code mean that click the graphic one time will increase 10 to
the variable's value
VBScript Example
ActionCmd.ButtonValueInput("Var.VariableGroup1.Variable1",1,10)
DiscreteValueInput
The discrete value input action
Define
DiscreteValueInput(expression ,trueValue ,falseValue)
Parameter
Data
Name Required/Optional Description
Type
expression Required String The variable expression
trueValue Required String The displayed value when the expression value is True
falseValue Required String The displayed value when the expression value is False
Example
For example,add the discrete value input action to the graphics(as VBScript below),when runtime,
click this graphics dialog box will pop up the discrete value input box,enter a value, click ok to assign
the input values to the associated variables
VBScript Example
ActionCmd.DiscreteValueInput("Var.VariableGroup1.Variable1","True","False")
StringValueInput
The string input action
Define
StringValueInput(expression ,isPassWord)
Parameter
Data
Name Required/Optional Description
Type
expression Required String The variable expression
isPassWord Required Boolean Whether the password is displayed
Example
For example,add the string input action to the graphics(as VBScript below),when
runtime, click this graphics dialog box will pop up the string input box,enter a value,
click ok to assign the input values to the associated variables
VBScript Example
ActionCmd.StringValueInput("Var.VariableGroup1.Variable1",False)
ToggleInput
The setting input
Define
ToggleInput(expression)
Parameter
Data
Name Required/Optional Description
Type
expression Required String The name of variable
Example
Set the value of "variable" to "0" or "1"
VBScript Example
ActionCmd.ToggleInput("Var.Script.variable")
HMICmd
Operating picture commands
Methods list
Name Description
CloseDialogWindow Close the dialog window
CloseWindow Close window
ExitApplication Exit the program
ExitApplication Exit the program
To obtain the value of the
GetEnterKey
Enter Key
MaxWindow Maximize the window
MinWindow Minimize the Window
OpenDialogWindow Open the dialog window
OpenDialogWindow Open the dialog window
OpenDialogWindow Open the dialog window
OpenDialogWindow Open the dialog window
OpenDialogWindow Open the dialog window
OpenWindow Open the window
Just open the specified
OpenWindowAndCloseOther screen, close the other
picture
PrintFullWorkSpace Print the whole workspace
Save the full workspace as
SaveFullWorkSpaceAsImage
an image
CloseDialogWindow
Close the dialog window
Define
CloseDialogWindow()
Example
Close the dialog window
VBScript Example
HMICmd.CloseDialogWindow()
CloseWindow
Close window
Define
CloseWindow(windowName)
Parameter
Name Required/Optional Data Type Description
windowName Required String Screen name
Example
Close the window of screen 0.Close the window of screen 0,screen
1,screen 2,multiple images and so on.
VBScript Example
HMICmd.CloseWindow("Screen0") or
HMICmd.CloseWindow("Screen0,Screen1,Screen2")
ExitApplication
Exit application
Define
ExitApplication(isNeedNotice)
Parameter
Name Required/Optional Data Type Description
isNeedNotice Required Bool Is notice
Example
Exit application
VBScript Example
HMICmd.ExitApplication(True)
ExitApplication
Exit application
Define
ExitApplication()
Example
Exit application
VBScript Example
HMICmd.ExitApplication()
GetEnterKey
To obtain the value of Enter Key
Define
GetEnterKey(eventArgs)
Parameter
Name Required/Optional Data Type Description
eventArgs Required String EventPara.EventArgs
Example
1.Add a "TextBox" and a "Rectangle" to the window;
2.Add a "TimerTicked Program" to "Window
Program":TextBox0.Focus(),make the cursor in the TextBox0;
3.Configure script to obtain the value of the Enter Key,if get the value
of the Enter Key,the color of Rectangle is red,else the color is blue;
VBScript Example
TextBox0.Focus()
If HMICmd.GetEnterKey(EventPara.EventArgs) = true
then
Rectangle0.Fill = Colors.Red
Else
Rectangle0.Fill = Colors.Blue
End If
MaxWindow
Maximize the window
Define
MaxWindow()
Example
Maximize the window
VBScript Example
HMICmd.MaxWindow()
MinWindow
Minimize the Window
Define
MinWindow()
Example
Minimize the Window
VBScript Example
HMICmd.MinWindow()
OpenDialogWindow
Open dialog window
Define
OpenDialogWindow(windowName)
Parameter
Data
Name Required/Optional Description
Type
windowName Required String The screen name
Example
Open dialog window
VBScript Example
HMICmd.OpenDialogWindow("Window0")
OpenDialogWindow
Open dialog window
Define
OpenDialogWindow(windowName,isShowTitle)
Parameter
Data
Name Required/Optional Description
Type
windowName Required String The window name
isShowTtile Required Bool Is show title
Call HMICmd.OpenDialogWindow("window0",true)
OpenDialogWindow
Open dialog window in the specified screen
Define
OpenDialogWindow(windowName,screenNum,isMode)
Parameter
Data
Name Required/Optional Description
Type
windowName Required String The window name
screenNum Required Int The screen number
isModel Required Bool Is modal window or not
Call HMICmd.OpenDialogWindow("window0",1,true)
OpenDialogWindow
Open dialog window in the specified screen
Define
OpenDialogWindow(windowName,screenNum,isMode,isFullScreen)
Parameter
Data
Name Required/Optional Description
Type
windowName Required String The window name
screenNum Required Int The screen number
isModel Required Bool Is modal window or not
isFullScreen Required Bool Is full screen or not
Call
HMICmd.OpenDialogWindow("Window0",1,true,true)
OpenDialogWindow
Open dialog window in the specified screen
Define
OpenDialogWindow(windowName,screenNum,isMode,left,top)
Parameter
Data
Name Required/Optional Description
Type
windowName Required String The window name
screenNum Required Int The screen number
isModel Required Bool Is modal window or not
The left end position of
left Optional Double
the window
The top end position of
top Optional Double
the window
Call
HMICmd.OpenDialogWindow("Window0",1,true,100,200)
OpenWindow
Open the window
Define
OpenWindow(windowName)
Parameter
Data
Name Required/Optional Description
Type
windowName Required String The screen name
Example
Open the screen 0 and 1 together
VBScript Example
HMICmd.OpenWindow("Screen0,Screen1")
OpenWindowAndCloseOther
Just open the specified screen, close the other screen
Define
OpenWindowAndCloseOther(windowName)
Parameter
Data
Name Requireed/Optional Description
Type
windowName Required String The screen name
Example
Open the screen 0 and 1 together, close the other screen
VBScript Example
HMICmd.OpenWindowAndCloseOther("Screen0,Screen1")
PrintFullWorkSpace
Print the whole workspace
Define
PrintFullWorkSpace()
Example
Print the whole workspace
VBScript Example
HMICmd.PrintFullWorkSpace()
SaveFullWorkSpaceAsImage
Save the full workspace as an image
Define
SaveFullWorkSpaceAsImage(filePath)
Parameter
Data
Name Required/Optional Description
Type
filePath Required String Absolute path of the image
Example
Save the full workspace as the image0
VBScript Example
HMICmd.SaveFullWorkSpaceAsImage("D:\image0.jpg")
IODataItem
IO data
Methods list
Name Description
GetDeviceStatus Get device status
Property list
Name Description
Address The communication address
Data conversion type Int, 0-no
transformation, 1-linear
DataConversionTypeInt
transformation, 2-root
transformation
Description Description
The maximum value of
MeasureHigh
engineering
The minimum value of
MeasureLow
engineering
Name Address name
ScanTime Scan cycle
VariablePath Alarm variable absolute path
Default
GetDeviceStatus
Get device status
Define
Int GetDeviceStatus()
Return
Int
Example
0 means normal communication, 2 means disconnection or stop
VBScript Example
IO.Device0.GetDeviceStatus()
Address
The communication address
Define
String Address
Description
Annotation
This property is read-only
Text0.Text = IO.Device0.NewAddres0.Address
DataConversionTypeInt
Data conversion type Int, 0-no transformation, 1-linear
transformation, 2-root transformation
Define
Int32 DataConversionTypeInt
Description
Annotation
This property is read/write
Example
Set to linear transformation
VBScript Example
IO.Device0.NewAddres0.DataConversionTypeInt = 1
Description
Description
Define
String Description
Description
Annotation
This property is read/write
Example
Get description information of "NewAddress0"
VBScript Example
Text0.Text = IO.Device0.NewAddress0.Description
MeasureHigh
The maximum value of engineering
Define
Object MeasureHigh
Description
Annotation
This property is read/write
Example
Set the maximum value of address of engineering
VBScript Example
IO.Device0.NewAddres0.MeasureHigh = 100
MeasureLow
The minimum value of engineering
Define
Object MeasureLow
Description
Annotation
This property is read/write
Example
Set the minimum value of the address to 0
VBScript Example
IO.Device0.NewAddres0.MeasureLow = 0
Name
Address name
Define
String Name
Description
Annotation
This property is read-only
Example
Get address name
VBScript Example
Text0.Text = IO.Device0.NewAddres0.Name
ScanTime
Scan cycle
Define
Int32 ScanTime
Description
Annotation
This property is read-only
Text0.Text = IO.Device0.NewAddres0.ScanTime
VariablePath
Variable absolute path
Define
String VariablePath
Description
Annotation
This property is read-only
Example
The specified address binding to the variable path
VBScript Example
IO.Device0.NewAddres0.VariablePath =
"var.NewVariable"
IODevice
Equipment base class and object associated with the underlying
IoServer
Property list
Name Description
Description Description
The last connection time of the
DeviceConnectLastTime
device
Get the communications
DeviceConnectPara
information of device
The last disconnection time of
DeviceDisconnectLastTime
the device
DeviceType The device type
Name The device name
Get the equipment status, 0-
Status
normal,2-disconnect or stop
Get the spend time that the
SpendTime
device needed to scan
Description
Description
Define
String Description
Description
Annotation
This property is read-only
Text0.Text = IO.Device0.Description
DeviceConnectLastTime
The last connection time of the device
Define
String DeviceConnectLastTime
Description
nnotation
A
This property is read-only
Text0.Text = IO.Device0.DeviceConnectLastTime
DeviceConnectPara
Get the communications information of device
Define
String DeviceConnectPara
Description
nnotation
A
This property is read-only
Text0.Text = IO.Device0.DeviceConnectPara
DeviceDisconnectLastTime
The last disconnection time of the device
Define
String DeviceDisconnectLastTime
Description
nnotation
A
This property is read-only
Text0.Text = IO.Device0.DeviceDisconnectLastTime
DeviceType
The device type
Define
String DeviceType
Description
Annotation
This property is read-only
Text0.Text = IO.Device0.DeviceType
Name
The device name
Define
String Name
Description
Annotation
This property is read-only
Example
Get device name
VBScript Example
Text0.Text = IO.Device0.Name
Status
Get the equipment status
Define
Int32 Status
Description
Annotation
This property is read/write
Return
0-normal,2-disconnect or stop
Example
Get equipment status
VBScript Example
Text0.Text = IO.Device0.Status
SpendTime
Get the spend time that the device needed to scan
Define
Int32 SpendTime
Description
nnotation
A
This property is read-only
Example Get the spend time that the device needed to scan
VBScript Example
Text0.Text = IO.Device0.SpendTime
IOManagement
IO management
Methods list
Name Description
The last connection time
GetDeviceConnectLastTime
of device
Get communications
GetDeviceConnectPara
information of device
Get the last disconnection
GetDeviceDisconnectLastTime
time of the device
GetDeviceStatus Get device status
Get address information
GetItemAddress that corresponds to the
address name
GetLocalIP Get local IP
GetLocalLansIP Get all Local Lans IP
GetMacAddress Get mac address
Get the spend time that
GetScanDeviceSpendTime
the device needed to scan
Get the file on remote
ReadRemoteFile
device
ReStart Restart device
Modify COM baud rate
SetDeviceCOMBaudRate
dynamically
Modify COM port
SetDeviceCOMPort
dynamically
Modify IP address
SetDeviceSocketIP
dynamically
Modify socket port
SetDeviceSocketPort
dynamically
StartDevice Start device
StopDevice Stop device
Write local file to remote
WriteRemoteFile
device
GetDeviceConnectLastTime
The last connection time of the device
Define
GetDeviceConnectLastTime(deviceName)
Parameter
Data
Name Required/Optional Description
Type
deviceName Required String The device name
Return
String
Example
Get the last connection time of device
VBScript Example
IOCmd.GetDeviceConnectLastTime("Device0")
GetDeviceConnectPara
Get the communications information of device
Define
GetDeviceConnectPara(deviceName)
Parameter
Data
Name Required/Optional Description
Type
deviceName Required String The device name
Return
String
Example
Get the communications information of device
VBScript Example
IOCmd.GetDeviceConnectPara("Device0")
GetDeviceDisconnectLastTime
Get the last disconnection time of device
Define
GetDeviceDisconnectLastTime(deviceName)
Parameter
Data
Name Required/Optional Description
Type
deviceName Required String The device name
Return
String
Example
Get the last disconnection time of device
VBScript Example
IOCmd.GetDeviceDisconnectLastTime("Device0")
GetDeviceStatus
Get device status
Define
GetDeviceStatus(devicename)
Parameter
Data
Name Required/Optional Description
Type
deviceName Required String Device name
Return
Int
Example
0-normal,2-disconnect or stop
VBScript Example
IOCmd.GetDeviceStatus("Device0")
GetItemAddress
Get address information that corresponds to the address name
Define
GetItemAddress(deviceName,addressName)
Parameter
Data
Name Required/Optional Description
Type
deviceName Required String The device name
addressName Required String The address name
Return
String
Example
Get address information that corresponds to the address name
VBScript Example
IOCmd.GetItemAddress("Device0","Address1")
GetLocalIP
Get local IP
Define
GetLocalIP( )
Return
String
Example
Get local IP
VBScript Example
IOCmd.GetLocalIP()
GetLocalLansIP
Get all Local Lans IP
Define
GetLocalLansIP()
Return
String
Example
Get all Local Lans IP
VBScript Example
List = IOCmd.GetLocalLansIP()
strs = ""
For i=0 To List.Length-1
strs =strs + CStr(List(i)) + " , "
Next
MsgBox strs
GetMacAddress
Get mac address
Define
GetMacAddress(ip)
Parameter
Data
Name Required/Optional Description
Type
ip Required String IP address
Return
String
Example
Get the device's mac address which specified IP
VBScript Example
IOCmd.GetMacAddress("192.168.1.1")
GetScanDeviceSpendTime
Get the spend time that the device needed to scan
Define
GetScanDeviceSpendTime(deviceName)
Parameter
Data
Name Required/Optional Description
Type
deviceName Required String Device name
Return
String
Example
Get the spend time that the device needed to scan
VBScript Example
IOCmd.GetScanDeviceSpendTime("Device0")
ReadRemoteFile
Get the file on remote device
Define
String
ReadRemoteFile(localPath,IsReplaceFile,deviceName,remoteIP,port,remoteFilePath,timeOutSecond
s,isDeleteFileReadFinish)
Parameter
Data
Name Required/Optional Description
Type
localPath Required String Local path
IsReplaceFile Required Bool Whether replace or not
deviceName Required String The device name
remoteIP Required String The IP of the remote device
port Required Int Port
remoteFilePath Required String The file path on the remote device
timeOutSeconds Required Int Timeout
isDeleteFileReadFinish Required Bool Whether delete file or not after finish
Return
String
Example
Get the file on remote device
VBScript Example
IOCmd.ReadRemoteFile("D:\",true,"device0","192.168.1.1",21,"E:\",100,false)
ReStart
Restart device
Define
Int ReStart(deviceName)
Parameter
Data
Name Required/Optional Description
Type
deviceName Required String The device name
Return
Int
Example
Restart device
VBScript Example
IOCmd.ReStart("Device0")
SetDeviceCOMBaudRate
Modify the COM baud rate dynamically
Define
bool SetDeviceCOMBaudRate(deviceName,baudRate)
Parameter
Data
Name Required/Optional Description
Type
deviceName Required String The device name
baudRate Required String Baud rate
Return
Bool
Example
Modify the COM baud rate dynamically
VBScript Example
IOCmd.SetDeviceCOMBaudRate("Device0","115200")
SetDeviceCOMPort
Modify the COM port dynamically
Define
bool SetDeviceCOMPort(deviceName,comPort)
Parameter
Data
Name Required/Optional Description
Type
deviceName Required String The device name
comPort Required String The COM port
Return
Bool
Example
Modify the COM port dynamically
VBScript Example
IOCmd.SetDeviceCOMPort("Device0","COM1")
SetDeviceSocketIP
Modify IP address dynamically
Define
bool SetDeviceSocketIP(deviceName,ip)
Parameter
Data
Name Required/Optional Description
Type
deviceName Required String The device name
ip Required String IP address
Return
Bool
Example
Modify IP address dynamically
VBScript Example
IOCmd.SetDeviceSocketIP("Device0","192.168.1.100")
SetDeviceSocketPort
Modify socket port dynamically
Define
bool SetDeviceSocketPort(deviceName,port)
Parameter
Data
Name Required/Optional Description
Type
deviceName Required String The device name
port Required String Port
Return
Bool
Example
Modify socket port dynamically
VBScript Example
IOCmd.SetDeviceSocketPort("Device0","100")
StartDevice
Start device
Define
StartDevice(devicename)
Parameter
Data
Name Required/Optional Description
Type
Device name(used to
deviceName Required String
obtain the driver name)
Return
Int
Example
Start device
VBScript Example
IOCmd.StartDevice("Device0")
StopDevice
Stop device
Define
StopDevice(deviceName)
Parameter
Data
Name Required/Optional Description
Type
deviceName Required String Device name
Return
Int
Example
Stop device
VBScript Example
IOCmd.StopDevice("Device0")
WriteRemoteFile
Write local file to remote device
Define
String
WriteRemoteFile(localPathFile,deviceName,remoteIP,port,remoteFilePath,timeOutSeco
nds)
Parameter
Data
Name Required/Optional Description
Type
localPathFile Required String Local file path
deviceName Required String The device name
remoteIP Required String Remote device's IP
port Required Int Port
remoteFilePath Required String File path of remote file
timeOutSeconds Required Int Timeout
Return
String
Example
Write local file to remote device
VBScript Example
IOCmd.WriteRemoteFile("D:\","device0","192.168.1.1",21,"E:\",100)
AnalogVariable
Analog variable
Methods list
Name Description
The return value transfer into the
ToString
specified format string
ChangeValue Change variable value
Property list
Name Description
AbsolutePath Variable absolute path
Dead zone, variable extent of change
DeadBand
as a minimum
Decimal digits, value range is from 0 to
DecimalPlaces
15
Description The description of variable
EngineeringUnit The Engineering unit
InitValue Variable initial value
Whether to save the current value
IsInitValueSaved
when the program exits
MaxValue The maximum value of the variable
MinValue The minimum value of the variable
Name The variable name
UniqueIdentifier The unique identifier
Value The value of variable,object type
To obtain a variable's value with the
ValueAndUnit
additional project unit
ValueAsDouble Variable value
ToString
The return value transfer into the specified format string
Define
ToString(format)
Parameter
Data
Name Required/Optional Description
Type
format Required String Format
Return
The return value transfer into the specified format string
Example
VBScript Example
cc = Var.Analog1.ToString("C")
MsgBox cc
ChangeValue
Change variable value
Define
ChangeValue(value,reason)
Parameter
Data
Name Required/Optional Description
Type
value Required Double Target value
This value will be entered into
reason Required String
the operation variable
Return
void
Example
Change variable value
VBScript Example
Call Var.Analog1.ChangeValue(9.1,"test")
AbsolutePath
Variable absolute path
Define
String AbsolutePath
Description
Annotation
This property is read-only
Example
Display the variable full path
VBScript Example
TextBox0.Text =
Var.NewVariableGroup.NewVariable.AbsolutePath
DeadBand
Dead zone, variable extent of change as a minimum
Define
Double DeadBand
Description
Annotation
This property is read/write
Example
Set dead zone to 2
VBScript Example
Var.NewVariableGroup.NewVariable2.DeadBand = 2
DecimalPlaces
Decimal digits, value range is from 0 to 15
Define
Int32 DecimalPlaces
Description
Annotation
This property is read/write
Example
Set the decimal digits to 5
VBScript Example
Var.NewVariableGroup.NewVariable2.DecimalPlaces =
5
Description
The description of variable
Define
String Description
Description
Annotation
This property is read/write
Var.NewVariableGroup.NewVariable.Description = "an
analog variable"
EngineeringUnit
The Engineering unit
Define
String EngineeringUnit
Description
Annotation
This property is read/write
Example
Set the engineering unit to degrees Celsius
VBScript Example
Var.NewVariableGroup.NewVariable2.EngineeringUnit
= "Degrees Celsius"
InitValue
Variable initial value
Define
Int InitValue
Description
Annotation
This property is read/write
TextBox0.Text = Var.Variable.InitValue
IsInitValueSaved
Whether to save the current value when the program exits
Define
Boolean IsInitValueSaved
Description
Annotation
This property is read/write
Example
Set the property to true
VBScript Example
Var.NewVariableGroup.NewVariable.IsInitValueSaved
= true
MaxValue
The maximum value of the variable
Define
Double MaxValue
Description
Annotation
This property is read/write
Example
Set the maximum value of the variable to 200
VBScript Example
Var.NewVariableGroup.NewVariable2.MaxValue = 200
MinValue
The minimum value of the variable
Define
Double MinValue
Description
Annotation
This property is read/write
Example
The minimum value of the variable to -200
VBScript Example
Var.NewVariableGroup.NewVariable2.MinValue = -200
Name
The variable name
Define
String Name
Description
Annotation
This property is read-only
Example
Display the variable name
VBScript Example
TextBox0.Text =
Var.NewVariableGroup.NewVariable.Name
UniqueIdentifier
The unique identifier
Define
Int32 UniqueIdentifier
Description
Annotation
This property is read-only
Example
Display unique identifier
VBScript Example
TextBox0.Text =
Var.NewVariableGroup.NewVariable.UniqueIdentifier
Value
The variable value,object type
Define
Object Value
Description
Annotation
This property is read/write
Example
Modify the value of the variable to 50
VBScript Example
Var.NewVariableGroup.NewVariable2.Value = 50
ValueAndUnit
To obtain a variable's value with the additional project unit
Define
String ValueAndUnit
Description
Annotation
The property is read-only
Example
Display the value of variable and the engineering unit
VBScript Example
TextBox0.Text =
Var.NewVariableGroup.NewVariable2.ValueAndUnit
ValueAsDouble
The variable value
Define
Double ValueAsDouble
Description
Annotation
This property is read/write
Example
Modify the value of variable to 200
VBScript Example
Vars.NewVariableGroup.NewVariable.ValueAsDouble =
200
DigitalVariable
The digital variable
Methods list
Name Description
ChangeValue Change variable value
Property list
Name Description
AbsolutePath Absolute path of variable
Description Discription of variable
InitValue Variable initial value
Whether to save the current value
IsInitValueSaved
when the program exits
Name Variable name
UniqueIdentifier The unique identifier
Value Value of variable,object type
ValueAsBool Value of variable
ChangeValue
Change variable value
Define
ChangeValue(value,reason)
Parameter
Data
Name Required/Optional Description
Type
value Required Bool Target value
This value will be entered into
reason Required String
the operation variable
Return
void
Example
Change variable value
VBScript Example
Call Var.Digital1.ChangeValue(True,"test")
AbsolutePath
Variable absolute path
Define
String AbsolutePath
Description
Annotation
This property is read-only
Example
Display the variable full path
VBScript Example
TextBox0.Text =
Var.NewVariableGroup.NewVariable.AbsolutePath
Description
The description of variable
Define
String Description
Description
Annotation
This property is read/write
Var.NewVariableGroup.NewVariable.Description = "a
digital variable"
InitValue
Variable initial value
Define
Bool InitValue
Description
Annotation
This property is read/write
TextBox0.Text = Var.Digital1.InitValue
IsInitValueSaved
Whether to save the current value when the program exits
Define
Boolean IsInitValueSaved
Description
Annotation
This property is read/write
Example
Set the property to true
VBScript Example
Var.NewVariableGroup.NewVariable.IsInitValueSaved
= true
Name
The variable name
Define
String Name
Description
Annotation
This property is read-only
Example
Display the variable name
VBScript Example
TextBox0.Text =
Var.NewVariableGroup.NewVariable.Name
UniqueIdentifier
The only label ID
Define
Int32 UniqueIdentifier
Description
nnotation
A
This property is read-only
Example
Display the only label ID
VBScript Example
TextBox0.Text =
Var.NewVariableGroup.NewVariable.UniqueIdentifier
Value
The value of variable,object type
Define
Object Value
Description
Annotation
This property is read/write
Var.NewVariableGroup.NewVariable1.Value = 50
ValueAsBool
The value of variable
Define
Boolean ValueAsBool
Description
nnotation
A
This property is read/write
Example
Set the value of variable to true
VBScript Example
Var.NewVariableGroup.NewVariable1.ValueAsBool =
true
SystemVariable
System variable
Property list
Name Description
CurrentUserName The current login user
Date The date string of current system
The number of days of the current
Day
system date
What day of the week of the current
DayOfWeek
system date
The day of the year of the current
DayOfYear
system date
The project running time,the unit is in
ElapsedTime
seconds
Whether there is a alarm in the current
HasAlarm
system
Hour The current system time in hour
Millisecond The current system time in millisecond
Minute The current system time in minute
Month The current system time in month
Now The date and time of current system
ProjectDir Current project directory
Second The current system time in second
StartTime The start time of current project
Time The string of current system time
Year The current system date
CurrentUserName
The current login user
Define
String CurrentUserName
Description
Annotation
This property is read-only
Example
Display the current login user
VBScript Example
TextBox0.Text = Sys.CurrentUserName
Date
The date string of current system
Define
String Date
Description
Annotation
The property is read-only
Example
Display the string of current system date
VBScript Example
TextBox0.Text = Sys.Date
Day
The number of days of the current system date
Define
Int32 Day
Description
Annotation
This property is read-only
Example
Display the number of days of the current system date
VBScript Example
TextBox0.Text = Sys.Day
DayOfWeek
The day of week of the current system date
Define
Int32 DayOfWeek
Description
Annotation
This property is read-only
Example Display the day of the week of the current system date
VBScript Example
TextBox0.Text = Sys.DayOfWeek
DayOfYear
The day of year of the current system date
Define
Int32 DayOfYear
Description
Annotation
This property is read-only
TextBox0.Text = Sys.DayOfYear
ElapsedTime
The project running time,the unit is in seconds
Define
Double ElapsedTime
Description
Annotation
This property is read-only
TextBox0.Text = Sys.ElapsedTime
HasAlarm
Whether there is alarm in the current system
Define
Boolean HasAlarm
Description
Annotation
This property is read-only
TextBox0.Text = Sys.HasAlarm
Hour
The current system time in hour
Define
Int32 Hour
Description
Annotation
This property is read-only
TextBox0.Text = Sys.Hour
Millisecond
The current system time in millisecond
Define
Int32 Millisecond
Description
Annotation
This property is read-only
TextBox0.Text = Sys.Millisecond
Minute
The current system time in minute
Define
Int32 Minute
Description
Annotation
This property is read-only
Example
Display the current system time in minute
VBScript Example
TextBox0.Text = Sys.Minute
Month
The current system time in month
Define
Int32 Month
Description
Annotation
This property is read-only
Example
Display the current system time in month
VBScript Example
TextBox0.Text = Sys.Month
Now
The date and time of current system
Define
String Now
Description
Annotation
This property is read-only
Example
Display the date and time of current system
VBScript Example
TextBox0.Text = Sys.Now
ProjectDir
Current project directory
Define
String ProjectDir
Description
Annotation
This property is read-only
TextBox0.Text = Sys.ProjectDir
Second
The current system time in seconds
Define
Int32 Second
Description
Annotation
This property is read-only
Example
Display the current system time in seconds
VBScript Example
TextBox0.Text = Sys.Second
StartTime
The start time of current project
Define
DateTime StartTime
Description
Annotation
This property is read-only
Example
Display the start time of current project
VBScript Example
TextBox0.Text = Sys.StartTime
Time
The string of current system time
Define
String Time
Description
Annotation
This property is read-only
Example
Display the string of current system time
VBScript Example
TextBox0.Text = Sys.Time
Year
The current system date
Define
Int32 Year
Description
Annotation
This property is read-only
TextBox0.Text = Sys.Year
VariableGroup
The variable group
Property list
Name Description
AbsolutePath The variable group absolute path
Description The description of variable group
Name The name of variable group
UniqueIdentifier The only label ID
AbsolutePath
The variable group absolute path
Define
String AbsolutePath
Description
Annotation
This property is read-only
TextBox0.Text = Var.NewVariableGroup1.AbsolutePath
Description
The description of variable group
Define
String Description
Description
Annotation
This property is read/write
Example
Modify the description of variable group to "Switch variable"
VBScript Example
Var.NewVariableGroup1.Description = "Switch
variable"
Name
Variable group name
Define
String Name
Description
Annotation
This property is read-only
Example
Display the variable group name
VBScript Example
TextBox0.Text = Var.NewVariableGroup1.Name
UniqueIdentifier
The only label ID
Define
Int32 UniqueIdentifier
Description
Annotation
This property is read-only
Example
Display the only label ID of variable group
VBScript Example
TextBox0.Text =
Var.NewVariableGroup1.UniqueIdentifier
TextVariable
String variable
Methods list
Name Description
ChangeValue Change variable value
Property list
Name Description
AbsolutePath Variable absolute path
Description The description of variable
InitValue Variable initial value
Whether to save the current value
IsInitValueSaved
when the program exits
Name Variable name
UniqueIdentifier The only label ID
Value The value of variable,object type
ValueAsString The variable value
ChangeValue
Change variable value
Define
ChangeValue(value,reason)
Parameter
Data
Name Required/Optional Description
Type
value Required String Target value
This value will be entered into
reason Required String
the operation variable
Return
void
Example
Change variable value
VBScript Example
Call Var.Digital1.ChangeValue("Value","test")
AbsolutePath
Variable absolute path
Define
String AbsolutePath
Description
Annotation
This property is read-only
Example
Pop-up a dialog to display the variable full path
VBScript Example
MsgBox
Var.NewVariableGroup.NewVariable.AbsolutePath
Description
The description of variable
Define
String Description
Description
Annotation
This property is read/write
Var.NewVariableGroup.NewVariable.Description = "a
string variable"
InitValue
Variable initial value
Define
String InitValue
Description
nnotation
A
This property is read/write
TextBox0.Text = Var.String1.InitValue
IsInitValueSaved
Whether to save the current value when the program exits
Define
Boolean IsInitValueSaved
Description
Annotation
This property is read/write
Example
Set the property to true
VBScript Example
Var.NewVariableGroup.NewVariable.IsInitValueSaved
= true
Name
The variable name
Define
String Name
Description
Annotation
This property is read-only
Example
Display the variable name by pop-up a dialog
VBScript Example
MsgBox Var.NewVariableGroup.NewVariable.Name
UniqueIdentifier
The only label ID
Define
Int32 UniqueIdentifier
Description
Annotation
This property is read-only
Example
Display the only label ID by pop-up a dialog
VBScript Example
MsgBox
Var.NewVariableGroup.NewVariable.UniqueIdentifier
Value
The value of variable,object type
Define
Object Value
Description
Annotation
This property is read/write
Var.NewVariableGroup.NewVariable.ValueAsString =
"pipeline"
ValueAsString
Variable value
Define
String ValueAsString
Description
Annotation
This property is read/write
Var.NewVariableGroup.NewVariable.ValueAsString =
"Pipe"
VariableCmd
Variable command
Methods list
Name Description
Get number of variables
GetExtendedDomainCount which specified the domain
and types
Get the set of variables which
GetExtendedDomainVars specified the domain and
types
Get values of variables which
GetVariableValue
is specified the path
Set values of variables which
SetVariableValue
is specified the path
GetExtendedDomainCount
Get number of variables which specified the domain and types
Define
GetExtendedDomainCount(extendedDomain,varType)
Parameter
Data
Name Required/Optional Description
Type
extendedDomain Required String Extended domain
Variable type,0
means analog,1
varType Required Int
means digital,2
means string
Example
Get number of string variables which domain name is "aaa"
VBScript Example
TextBox0.Text =
VarCmd.GetExtendedDomainCount("aaa",2)
GetExtendedDomainVars
Get the set of variables which specified the domain and types
Define
GetExtendedDomainVars(extendedDomain,varType)
Parameter
Data
Name Required/Optional Description
Type
extendedDomain Required String Extended domain
Variable type,0
means analog,1
varType Required Int
means digital,2
means string
Example
Get the set of string variables which domain name is "aaa"
VBScript Example
List = VarCmd.GetExtendedDomainVars("aaa",2)
Count = VarCmd.GetExtendedDomainCount("aaa",2)
For i = 0 To Count - 1
MsgBox CStr(LIST(i))
Next
GetVariableValue
Get values of variables which is specified the path
Define
GetVariableValue(VariablePath , errorValue)
Parameter
Data
Name Required/Optional Description
Type
VariablePath Required String The variable path
Return an error value,
return when the
errorValue Required Object
variable path was not
found
Example
Get the value of variable "Var.variable0"
VBScript Example
TextBox0.Text =
VarCmd.GetVariableValue("Var.Variable0",0)
SetVariableValue
Set values of variables which is specified the path
Define
SetVariableValue(VariablePath , Value)
Parameter
For i = 0 To 2
tt = VarCmd.GetVariableValue("Var.variable"&i, 0)
Call
VarCmd.SetVariableValue("Var.VariableGroup0.variable"&i,tt)
Next
ReportCommand
The report command scripts
Methods list
Name Description
Export the DataTable to
DirectExportDataToExcel
Excel table
Import the content of the
DirectImportToDataTable
table to DataTable
Import the specified
DirectImportToDataTable content of the table to the
DataTable
DirectPrintDataTable DataTable print
Print directly according to
DirectPrintTemplateForPath
the template
Export the history data and
curve control pictures to
ExportDataByTemplate
excel according to the
template
Export the real-time data
and curve control pictures
ExportDataByTemplate
to excel according to the
template
ExportDataTableToExcel Export data to excel
Export the history data to
ExportHistoryDataByTemplate excel according to the
template
ReadCsvFileByTemplate Read CSV file
SetWorkSheetEndTime Set the end time of query
Set the time interval of
SetWorkSheetIntervalTime
query
SetWorkSheetStartTime Set the start time of query
DirectExportDataToExcel
Export the DataTable to Excel table
Define
DirectExportDataToExcel(data ,excelFilePath ,version)
Parameter
Data
Name Required/Optional Description
Type
data Required DataTable Data source
excelFilePath Required String The excel file path
Excel version(0:office97To2003;1:office07 and newer
version Required Int
version)
Example
1. Get the data in the database access table and export it with the current time as the Excel name
VBScript Example
Example
Import file data of the specified path and display it in the report control
VBScript Example
dt =
ReportCmd.DirectImportToDataTable("D:\datatable.xlsx")
Call Report0.ShowDataTableForReport(1,1,dt)
DirectImportToDataTable
Import the table contents into the DataTable
Define
DirectImportToDataTable(excelFilePath ,rowHeaderIndex ,startRowIndex
,endRowIndex )
Parameter
Data
Name Required/Optional Description
Type
excelFilePath Required String The file path
Index of the row in which the
rowHeaderIndex Required Int
header is placed,starting at 1
startRowIndex Required Int Index of start row
endRowIndex Required Int Index of end row
Example
Import the data from line 5 to line 20 of the file in the specified path and display it
in the report control
VBScript Example
dt =
ReportCmd.DirectImportToDataTable("D:\datatable.xlsx",0,5,20)
Call Report0.ShowDataTableForReport(1,1,dt)
DirectPrintDataTable
DataTable print
Define
DirectPrintDataTable(data ,pageMediaSize ,topMargin ,bottomMargin
,leftMargin ,rightMargin ,lanscape ,scale)
Parameter
Data
Name Required/Optional Description
Type
data Required DataTable Data Source
pageMediaSize Required Int Page setup,8 is A4
The top margin,default
topMargin Required Double
value is 0
The bottom
bottomMargin Required Double margin,default value is
0
The left margin,default
leftMargin Required Double
value is 0
The right margin,default
rightMargin Required Double
value is 0
The print direction,1 is
lanscape Required Int lateral, 2 is in the
longitudinal direction
Factor,the default value
scale Required Int
is 100
Example
Custom Settings page to print the DataTable data
VBScript Example
dt =
ReportCmd.DirectImportToDataTable("D:\datatable.xlsx")
Call
ReportCmd.DirectPrintDataTable(dt,8,0,0,0,0,1,100)
DirectPrintTemplateForPath
Print directly according to the template
Define
DirectPrintTemplateForPath(Path,pageMediaSize,topMargin,bottomMargin ,leftMargin
,rightMargin,lanscape,scale)
Parameter
Data
Name Required/Optional Description
Type
path Required String The file path
pageMediaSize Required Int Page setup,8 is A4
topMargin Required Double The top margin,default value is 0
bottomMargin Required Double The bottom margin,default value is 0
leftMargin Required Double The left margin,default value is 0
rightMargin Required Double The right margin, default value is 0
The print direction,1 is lateral, 2 is in the
lanscape Required Int
longitudinal direction
scale Required Int Factor,the default value is 100
Print directly according to the template
VBScript Example
Call
ReportCmd.DirectPrintTemplateForPath("D:\test.xlsx",8,0,0,0,0,1,100)
ExporDataByTempLate
Export the history data and curve control pictures to excel according to the template
Define
ExportDataByTemplate(fileName ,templateName,dt ,imageBytes)
Parameter
Data
Name Required/Optional Description
Type
fileName Required String The file path saved
templateName Required String Report template name
dt Required DataTable The export data
imageBytes Required String The picture string,each picture are separated by“|”
Example
Export three historical curve data and images to Excel table according to the report template
VBScript Example
Data
Name Required/Optional Description
Type
fileName Required String The file path saved
templateName Required String Report template name
imageBytes Required String The picture string,each picture are separated by “|”
Example
Export two real-time curve data and images to Excel table according to the report template
"RealReport0"
VBScript Example
Call
ReportCmd.ExportDataByTemplate("D:\Test.xlsx","RealReport0",RealTimeChart0.Ar
ExportDataTableToExcel
Export data to excel
Define
ExportDataTableToExcel(fileName , dt , sheetIndex , rowIndex , colIndex ,
overWrite)
Parameter
Data
Name Required/Optional Description
Type
fileName Required String The file path saved
dt Required DataTable Data source
sheetIndex Required Int Worksheet index
rowIndex Required Int Start row number
colIndex Required Int Start column number
overWrite Required Bool Whether to overwrite the original sheet
Example
Export the data in the database to the worksheet0 of the file test1.xls, and display
the data from the second row and the third column
VBScript Example
dt = DbAccess.DatabaseAccess1.GetTable()
Call
ReportCmd.ExportDataTableToExcel("D:\test1.xls",dt,0,2,3,True)
ExportHistoryDataByTemplate
Export the history data to excel according to the template
Define
ExportDataByTemplate(templateName ,excelFileTime)
Parameter
Data
Name Required/Optional Description
Type
templateName Required String The report template name
excelFileTime Required String The file path
Example
Export the last hour of historical data to Excel according to report template "report 0"
VBScript Example
starttime = dateadd("h",-1,now())
Call ReportCmd.SetWorkSheetStartTime(0,starttime)
Call ReportCmd.SetWorkSheetIntervalTime(0,1000)
Call ReportCmd.SetWorkSheetEndTime(0,Sys.Now)
Call
ReportCmd.ExportHistoryDataByTemplate("Report0","D:\123.xlsx")
ReadCsvFileByTemplate
Read CSV file
Define
ReadCsvFileByTemplate(templatePath,csvFilePath)
Parameter
Data
Name Required/Optional Description
Type
templatePath Required String Report template name
csvFilePath Required String The file path
Example
The report template "Report 0" associates the real-time variables, and then
executes this script to assign the values of the corresponding cells in the
.csv file to the variables in the template.
VBScript Example
Call
ReportCmd.ReadCsvFileByTemplate("Report0","D:\test.csv")
SetWorkSheetEndTime
Set the end time of query
Define
SetWorkSheetEndTime(sheetIndex ,EndTime)
Parameter
Data
Name Required/Optional Description
Type
sheetIndex Required Int The worksheet index
EndTime Required DateTime End time
Example
Set the current system time to end time
VBScript Example
Call ReportCmd.SetWorkSheetEndTime(0,Sys.Now)
SetWorkSheetIntervalTime
Set the time interval of query
Define
SetWorkSheetIntervalTime(sheetIndex ,intervalTime)
Parameter
Data
Name Required/Optional Description
Type
sheetIndex Required Int The worksheet index
intervalTime Required Int64 Time interval
Example
Set the time interval to 1 s
VBScript Example
Call ReportCmd.SetWorkSheetIntervalTime(0,1000)
SetWorkSheetStartTime
Set the start time of query
Define
SetWorkSheetStartTime(sheetIndex ,StartTime)
Parameter
Data
Name Required/Optional Description
Type
sheetIndex Required Int The worksheet index
StartTime Required DateTime Start time
Example
Set the current system time to start time
VBScript Example
Call ReportCmd.SetWorkSheetStartTime(0,Sys.Now)
AlarmGroup
Alarm group
Property list
Name Description
AbsolutePath The full path of alarm group
The number of the alarm group
AckedAlarmCount
currently in responses state
The number of the alarm group
AlarmCount
currently in alarm state
The number of the alarm group
AllAlarmCount
currently in all alarms and responses
Description The description of alarm group
Whether there is alarm in the current
HasAlarm
alarm group
Name The name of alarm group
UniqueIdentifier The only label ID of alarm group
AbsolutePath
The full path of alarm group
Define
String AbsolutePath
Description
Annotation
This property is read-only
Text0.Text = Alarm.AlarmGroup0.AbsolutePath
AckedAlarmCount
The number of the alarm group currently in responses state
Define
Int32 AckedAlarmCount
Description
Annotation
This property is read-only
Example
Display the number of the alarm group currently in responses
state by text control
VBScript Example
Text0.Text = Alarm.AlarmGroup0.AckedAlarmCount
AlarmCount
The number of the alarm group currently in alarm state
Define
Int32 AlarmCount
Description
Annotation
This property is read-only
Text0.Text = Alarm.AlarmGroup0.AlarmCount
AllAlarmCount
The number of the alarm group currently in alarms and responses
Define
Int32 AllAlarmCount
Description
Annotation
This property is read-only
Text0.Text = Alarm.AlarmGroup0.AllAlarmCount
Description
The description of alarm group
Define
String Description
Description
Annotation
This property is read/write
Example
Modify the property to "Temperature alarm group"
VBScript Example
Example
Display whether there is alarm in the "AlarmGroup0" by text control
VBScript Example
Text0.Text = Alarm.AlarmGroup0.HasAlarm
Name
The name of alarm group
Define
String Name
Description
Annotation
This property is read-only
Text0.Text = Alarm.AlarmGroup.Name
UniqueIdentifier
The unique identifier of alarm group
Define
Int32 UniqueIdentifier
Description
Annotation
This property is read-only
Text0.Text = Alarm.AlarmGroup0.UniqueIdentifier
AnalogAlarm
Analog variable alarm model
Property list
Name Description
AbsolutePath Absolute path of alarm
AlarmType Alarm type
Current value of alarm
CurrentValue
variable
Alarm variable current
CustomerExpressionContent
custom expression Content
Alarm variable current
CustomerExpressionValue
custom expression Value
Analog deviation or the limit
DelayValue of the alarm delay time, the
unit is second
Description Description of alarm
The analog alarm deviation
DeviationDeadBandValue
value of the dead zone
The analog alarm deviation
DeviationTargetValue
value of the target
HighContent Analog high alarm text
The text of analog high high
HighHighContent
alarm
Analog high high alarm
HighHighValue
value
HighValue Analog high alarm value
The last time of the alarm
LastTriggerTime
time
The alarm level,the highest
level is 999,0-199:slight,
Level 200-399:lighter,400-599:
general,600-799:heavier,
800-999:serious
LimitDeadBandValue The upper or lower limits of
dead zone value of the
analog alarm
LowContent The text of analog low alarm
The alarm text of the analog
LowerDeviationContent
deviation lower limit
The alarm value of the
LowerDeviationValue
analog deviation lower limit
The text of analog low low
LowLowContent
alarm
The value of analog low low
LowLowValue
alarm
The value of analog low low
LowValue
alarm
Name The alarm name
The alarm text of analog
RateOfChangeContent
rate
The unit of change
RateOfChangeUnit rate,second is 1,minute is
60,hour is 3600
The alarm value of the
RateOfChangeValue
analog change rate
Alarm variable status, -1: no
alarm; 0: all alarms are
Status
restored; 1.new alarm; 2:
any alarm will be response
UniqueIdentifier The alarm unique identifier
The alarm text of the analog
UpperDeviationContent
deviation upper limit
The alarm value of the
UpperDeviationValue
analog deviation upper limit
AbsolutePath
The alarm absolute path
Define
String AbsolutePath
Description
Annotation
This property is read-only
Text0.Text =
Alarm.AlarmGroup0.AlarmVariable0.AbsolutePath
AlarmType
Alarm type
Define
Int32 AlarmType
Description
nnotation
A
This property is read/write
Alarm.AlarmGroup0.AlarmVariable0.AlarmType = 6
CurrentValue
Current value of alarm variable
Define
Object CurrentValue
Description
Annotation
This property is read-only
Text0.Text =
Alarm.AlarmGroup0.AlarmVariable.CurrentValue
CustomerExpressionContent
Alarm variable current custom expression content
Define
String CustomerExpressionContent
Description
Annotation
This property is read/write
Text0.Text =
Alarm.AlarmGroup0.AlarmVariable.CustomerExpressionContent
CustomerExpressionValue
Alarm variable current custom expression value
Define
ObjectCustomerExpressionvalue
Description
Annotation
This property is read/write
Text0.Text =
Alarm.AlarmGroup0.AlarmVariable.CustomerExpressionvalue
DelayValue
Analog deviation or the limit of the alarm delay time, the unit is
second
Define
Int32 DelayValue
Description
Annotation
This property is read/write
Example Modify the analog deviation or the limit of the alarm delay
time to 1 second
VBScript Example
Alarm.AlarmGroup0.AlarmVariable0.DelayValue = 1
Description
Alarm description
Define
String Description
Description
Annotation
This property is read/write
Alarm.AlarmGroup0.AlarmVariable0.Description =
"AlarmDescription"
DeviationDeadBandValue
The analog alarm deviation value of the dead zone
Define
Double DeviationDeadBandValue
Description
Annotation
This property is read/write
Example Modify the analog alarm deviation value of the dead zone to 1
VBScript Example
Alarm.AlarmGroup0.AlarmVariable0.DeviationDeadBandValue
= 1
DeviationTargetValue
The analog alarm deviation value of the target
Define
Double DeviationTargetValue
Description
Annotation
This property is read/write
Alarm.AlarmGroup0.AlarmVariable0.DeviationTargetValue
= 1
HighContent
Analog high alarm text
Define
String HighContent
Description
Annotation
This property is read/write
Alarm.AlarmGroup0.AlarmVariable0.HighContent =
"high alarm"
HighHighContent
The text of analog high high alarm
Define
String HighHighContent
Description
nnotation
A
This property is read/write
Example
Modify the analog high high alarm text to “high high alarm”
VBScript Example
Alarm.AlarmGroup0.AlarmVariable0.HighHighContent =
"high high alarm"
HighHighValue
Analog high high alarm value
Define
Double HighHighValue
Description
Annotation
This property is read/write
Alarm.AlarmGroup0.AlarmVariable0.HighHighValue = 1
HighValue
Analog high alarm value
Define
Double HighValue
Description
nnotation
A
This property is read/write
Alarm.AlarmGroup0.AlarmVariable0.HighValue = 1
LastTriggerTime
Time of last alarm trigger
Define
DateTime LastTriggerTime
Example Display the last time of the alarm time by text control
VBScript Example
Text0.Text =
Alarm.AlarmGroup0.AlarmVariable0.LastTriggerTime
Level
The alarm level,the highest level is 999,0-199:slight,200-399:
lighter,400-599:general,600-799:heavier,800-999:serious
Define
Int32 Level
Description
Annotation
This property is read/write
Example
Set alarm level
VBScript Example
Alarm.AlarmGroup0.AlarmVariable0.Level = 300
LimitDeadBandValue
The upper or lower limits of dead zone value of the analog alarm
Define
Double LimitDeadBandValue
Description
Annotation
This property is read/write
Example Modify the value of the upper or lower limits of the analog
alarm dead zone to 1
VBScript Example
Alarm.AlarmGroup0.AlarmVariable0.LimitDeadBandValue
= 1
LowContent
The text of analog low alarm
Define
String LowContent
Description
Annotation
This property is read/write
Alarm.AlarmGroup0.AlarmVariable0.LowContent = "low
alarm"
LowerDeviationContent
The alarm text of the analog deviation lower limit
Define
String LowerDeviationContent
Description
Annotation
This property is read/write
Example Modify the alarm text of the analog deviation lower limit to
“deviation lower limit alarm”
VBScript Example
Alarm.AlarmGroup0.AlarmVariable0.LowerDeviationContent
= "deviation lower limit alarm"
LowerDeviationValue
The alarm value of the analog deviation lower limit
Define
Double LowerDeviationValue
Description
Annotation
This property is read/write
Example Modify the alarm value of the analog deviation lower limit
to 1
VBScript Example
Alarm.AlarmGroup0.AlarmVariable0.LowerDeviationValue
= 1
LowLowContent
The text of analog low low alarm
Define
String LowLowContent
Description
Annotation
This property is read/write
Example Modify the text of analog low low alarm to “low low alarm”
VBScript Example
Alarm.AlarmGroup0.AlarmVariable0.LowLowContent =
"low low alarm"
LowLowValue
The value of analog low low alarm
Define
Double LowLowValue
Description
Annotation
This property is read/write
Alarm.AlarmGroup0.AlarmVariable0.LowLowValue = 1
LowValue
The value of analog low low alarm
Define
Double LowValue
Description
Annotation
This property is read/write
Alarm.AlarmGroup0.AlarmVariable0.LowValue = 1
Name
Alarm name
Define
String Name
Description
Annotation
This property is read-only
Text0.Text = Alarm.AlarmGroup0.AlarmVariable0.Name
RateOfChangeContent
The alarm text of analog rate
Define
String RateOfChangeContent
Description
Annotation
This property is read/write
Example Modify the alarm text of analog rate to “analog rate alarm”
VBScript Example
Alarm.AlarmGroup0.AlarmVariable0.RateOfChangeContent
= "analog rate alarm"
RateOfChangeUnit
The unit of change rate,second is 1,minute is 60,hour is 3600
Define
Int32 RateOfChangeUnit
Description
Annotation
This property is read/write
Alarm.AlarmGroup0.AlarmVariable0.RateOfChangeUnit
= 60
RateOfChangeValue
The alarm value of the analog change rate
Define
Double RateOfChangeValue
Description
Annotation
This property is read/write
Alarm.NewAlarmGroup.NewAlarm1.RateOfChangeValue =
1
Status
Alarm variable status, -1: no alarm; 0: all alarms are restored; 1.new
alarm; 2: any alarm will be response
Define
Int32 Status
Description
Annotation
This property is read-only
Example
Text display alarm variable status
VBScript Example
Text0.Text =
Alarm.AlarmGroup0.AlarmVariable0.Status
UniqueIdentifier
The alarm unique identifier
Define
Int32 UniqueIdentifier
Description
Annotation
This property is read-only
Text0.Text =
Alarm.AlarmGroup0.AlarmVariable0.UniqueIdentifier
UpperDeviationContent
The alarm text of the analog deviation upper limit
Define
String UpperDeviationContent
Description
Annotation
This property is read/write
Example Modify the content of the alarm text of the analog deviation
upper limit to “deviation upper limit alarm”
VBScript Example
Alarm.AlarmGroup0.AlarmVariable0.UpperDeviationContent
= "deviation upper limit alarm"
UpperDeviationValue
The alarm value of the analog deviation upper limit
Define
Double UpperDeviationValue
Description
Annotation
This property is read/write
Example Modify the alarm value of the analog deviation upper limit
to 1
VBScript Example
Alarm.AlarmGroup0.AlarmVariable0.UpperDeviationValue
= 1
DigitalAlarm
Digital variable alarm
Property list
Name Description
AbsolutePath Absolute path of alarm
AlarmType Alarm type
CurrentValue Current value of alarm variable
Description Description of alarm
The alarm level,the highest level is
999,0-199:slight,200-399:
Level
lighter,400-599:general,600-
799:heavier,800-999:serious
Name The alarm name
OffAlarmContent Digital close the alarm text
OffToOnAlarmContent Digital close to open alarm text
OnAlarmContent Digital open the alarm text
OnToOffAlarmContent Digital open to close alarm text
Alarm variable status, -1: no alarm;
0: all alarms are restored; 1.new
Status
alarm; 2: any alarm will be
response
UniqueIdentifier The unique identifier of alarm
AbsolutePath
The alarm absolute path
Define
String AbsolutePath
Description
Annotation
This property is read-only
Text0.Text =
Alarm.AlarmGroup0.AlarmVariable0.AbsolutePath
AlarmType
Alarm type
Define
Int32 AlarmType
Description
nnotation
A
This property is read/write
Alarm.AlarmGroup0.AlarmVariable0.AlarmType = 6
CurrentValue
Current value of alarm variable
Define
Object CurrentValue
Description
Annotation
This property is read-only
Text0.Text =
Alarm.AlarmGroup0.AlarmVariable.CurrentValue
Description
Alarm description
Define
String Description
Description
Annotation
This property is read/write
Alarm.AlarmGroup0.AlarmVariable0.Description =
"AlarmDescription"
Level
The alarm level,the highest level is 999,0-199:slight,200-399:
lighter,400-599:general,600-799:heavier,800-999:serious
Define
Int32 Level
Description
Annotation
This property is read/write
Example
Set alarm level
VBScript Example
Alarm.AlarmGroup0.AlarmVariable0.Level = 300
Name
Alarm name
Define
String Name
Description
Annotation
This property is read-only
Text0.Text = Alarm.AlarmGroup0.AlarmVariable0.Name
OffAlarmContent
Digital close the alarm text
Define
String OffAlarmContent
Description
Annotation
This property is read/write
Example
Modify the text of the digital close the alarm to "OffAlarm"
VBScript Example
Alarm.AlarmGroup0.AlarmVariable0.OffAlarmContent =
"OffAlarm"
OffToOnAlarmContent
Digital close to open alarm text
Define
String OffToOnAlarmContent
Description
Annotation
This property is read/write
Alarm.AlarmGroup0.AlarmVariable0.OffToOnAlarmContent
= "OffToOnAlarm"
OnAlarmContent
Digital open the alarm text
Define
String OnAlarmContent
Description
Annotation
This property is read/write
Example Modify the text of the digital open the alarm to "OnAlarm"
VBScript Example
Alarm.AlarmGroup0.AlarmVariable0.OnAlarmContent =
"OnAlarm"
OnToOffAlarmContent
Digital open to close alarm text
Define
String OnToOffAlarmContent
Description
Annotation
This property is read/write
Alarm.0AlarmGroup0.AlarmVariable0.OnToOffAlarmContent
= "OnToOffAlarm"
Status
Alarm variable status, -1: no alarm; 0: all alarms are restored; 1.new
alarm; 2: any alarm will be response
Define
Int32 Status
Description
Annotation
This property is read-only
Example
Text display alarm variable status
VBScript Example
Text0.Text =
Alarm.AlarmGroup0.AlarmVariable0.Status
UniqueIdentifier
The alarm unique identifier
Define
Int32 UniqueIdentifier
Description
Annotation
This property is read-only
Text0.Text =
Alarm.AlarmGroup0.AlarmVariable0.UniqueIdentifier
AlarmCmd
Alarm command
Methods list
Name Description
Check whether alarm variable
RecheckAlarm
generates alarm
SaveAlarmConfig Save alarm config
Property list
Name Description
AckedAlarmCount The number of alarm in reply condition
AlarmCount The number of alarm in the alarm state
All the number alarm which includes
AllAlarmCount
alarm and reply
RecheckAlarm
Check whether alarm variable generates alarm
Define
RecheckAlarm(alarmPaths)
Parameter
Data
Name Required/Optional Description
Type
alarmPaths Required String Format
Return
Void
Example
Check whether alarm variable generates alarm
VBScript Example
Call
AlarmCmd.RecheckAlarm("Alarm.AlarmValue1;Alarm.AlarmValue2")
SaveAlarmConfig
Save alarm configuration
Define
SaveAlarmConfig()
Example
Save alarm configuration
VBScript Example
Call AlarmCmd.SaveAlarmConfig()
AckedAlarmCount
The number of alarm in reply condition
Define
Int32 AckedAlarmCount
Description
nnotation
A
This property is read-only
Example
The text shows the number of alarms in the response state
VBScript Example
Text0.Text = AlarmCmd.AckedAlarmCount
AlarmCount
The number of alarm in the alarm state
Define
Int32 AlarmCount
Description
Annotation
This property is read-only
Example
The text shows the number of alarms in the alarm state
VBScript Example
Text0.Text = AlarmCmd.AlarmCount
AllAlarmCount
All the number alarm which includes alarm and reply
Define
Int32 AllAlarmCount
Description
nnotation
A
This property is read-only
Example
Display the number of alarm currently in alarms and responses by
text control
VBScript Example
Text0.Text = AlarmCmd.AllAlarmCount
AudioAlarmConfig
Alarm sound configuration
Methods list
Name Description
GetUserCustomContent Get the user custom content
SetUserCustomContent Set the user custom content
GetUserCustomContent
Get the user custom content
Define
GetUserCustomContent(category ,name ,isRecoveryTrigger)
Parameter
Data
Name Required/Optional Description
Type
Get the content of
the specified
category, 0-all
alarms, 1-alarm
category Required Int group, 2-alarm
level, 3-alarm
type, 4-alarm
variable, other
values are invalid
name Required Object When
category=0, the
Name value is is
invalid
When
category=1, the
Name value is the
Name of the
alarm group
When
category=2, the
Name value is: 1-
very serious, 2-
severe, 4-
general, 8- not
urgent, 16- slight
When
category=3, the
Name value is: 1-
low, 2- low, 4-
high, 8- high, 16-
small deviation,
32- large
deviation, 64-
change rate, 512-
on, 024- off,
2048- switch shift
When
category=4, the
Name value is the
path of the alarm
variable
Triggered when
isRecoveryTrigger Required Bool
alarm is restored
Example
VBScript Example
Text0.Text =
AudioAlarmConfig.GetUserCustomContent(2,4,False)
SetUserCustomContent
Set the user custom content
Define
SetUserCustomContent(category ,name ,isRecoveryTrigger ,newValue
,isLoopSpeech)
Parameter
Data
Name Required/Optional Description
Type
Get the content of
the specified
category, 0-all
alarms, 1-alarm
category Required Int
group, 2-alarm level,
3-alarm type, 4-
alarm variable, other
values are invalid
name Required Object When category=0,
the Name value is is
invalid
When category=1,
the Name value is
the Name of the
alarm group
When category=2,
the Name value is:
1- very serious, 2-
severe, 4- general,
8- not urgent, 16-
slight
When category=3,
the Name value is:
1- low, 2- low, 4-
high, 8- high, 16-
small deviation, 32-
large deviation, 64-
change rate, 512-
on, 024- off, 2048-
switch shift
When category=4,
the Name value is
the path of the alarm
variable
Triggered when
isRecoveryTrigger Required Bool
alarm is restored
User-defined voice
newValue Required String
content
Set whether to loop
isLoopSpeech Required Bool
playback
Example
VBScript Example
Call
AudioAlarmConfig.SetUserCustomContent(2,4,False,"Data
exception",False)
UserCmd
Authority management
Methods list
Name Description
AddUser Add user
Add users and set the user
AddUser
information
Modify the password of the current
ChangePassword
login user
ChangePasswordBox Change password
EditUser Edit user's name and description
Edit user's name ,description,type
EditUser
and password
EditUser Edit user’s type
GetAllUserCount Get all user count
GetAllUserNames Get all the user’s name list
GetCurrentUserName Get current user name
GetUserDescription Get current user description
GetUserNameByIndex Get user name by index
GetUserType Get current user type
Login User login authentication
LoginBox User login
Logout User logout
RemoveUser Remove user
UserManagerBox User management
Property list
Name Description
UserName Current user name
AddUser
Add user
Define
AddUser(userName ,password)
Parameter
Data
Name Required/Optional Description
Type
userName Required String username
password Required String password
Return
If add success,it will return True,otherwise return False
Example
First of all, the current user has login
VBScript Example
Call UserCmd.AddUser("username","123")
AddUser
Add users and set the user information
Define
AddUser(userName ,password ,description ,role)
Parameter
Data
Name Required/Optional Description
Type
userName Required String Username
password Required String Password
description Required String Description
role Required String User's role
Return
If success,it will return True,otherwise return False
Example
If you want to add an administrator, the current user must be a
system administrator, only one system administrator, and add the
operator cannot be deleted, the current user must be an
administrator
VBScript Example
Call UserCmd.AddUser("username","123","I am an
operator","Operator")
ChangePassword
Modify the password of the current login user
Define
ChangePassword(oldPassWord ,password)
Parameter
Data
Name Required/Optional Description
Type
oldPassword Required String Old password
password Required String New password
Return
If success,it will return True,otherwise return False
Example
Modify the password,first of all,you have login
VBScript Example
Call
UserCmd.ChangePassword("oldpassword","newpassword")
ChangePasswordBox
Change password
Define
ChangePasswordBox()
Example
Modify the password,first of all,you have login
VBScript Example
UserCmd.ChangePasswordBox()
EditUser
Edit user's name and description
Define
EditUser(userName ,newName ,description)
Parameter
Data
Name Required/Optional Description
Type
userName Required String Username
newName Required String The name to be modified
description Required String User description
Return
If success,it will return True,otherwise return False
Example
First of all, the administrator has been login
VBScript Example
UserCmd.EditUser("username","newname","HasBeenModified“)
EditUser
Edit user's name ,description,type and password
Define
EditUser(userName ,newName ,description , role , password)
Parameter
Data
Name Required/Optional Description
Type
userName Required String Username
newName Required String Edit username
description Required String Description
role Required String User's type
password Required String Password
Return
If success,it will return True,otherwise return False
Example The administrator has been login
VBScript Example
UserCmd.EditUser("username","username","EditUser","Operator","111111")
EditUser
Edit user’s type
Define
EditUser(userName , role)
Parameter
Data
Name Required/Optional Description
Type
userName Required String Username
role Required String User's type
Return
If success,it will return True,otherwise return False
Example
Types can be modified:Admin,Operator
VBScript Example
UserCmd.EditUser("username","Admin")
GetAllUserCount
Get all user count
Define
GetAllUserCount()
Return
Query all user count
Example
VBScript Example
TextBox0.Text = UserCmd.GetAllUserCount()
GetAllUserNames
Get all the user’s name list
Define
GetAllUserNames()
Example
All the user’s name list
VBScript Example
TextBox0.Text = UserCmd.GetAllUserNames()
GetCurrentUserName
Get current user name
Define
GetCurrentUserName()
Return
Return current user name
Example
VBScript Example
TextBox0.Text = UserCmd.GetCurrentUserName()
GetUserDescription
Get current user description
Define
GetUserDescription(userName)
Parameter
Data
Name Required/Optional Description
Type
userName Required String User name
Return
Get user description
Example
VBScript Example
TextBox0.Text = UserCmd.GetUserDescription("user")
GetUserNameByIndex
Get user name by index
Define
GetUserNameByIndex(index)
Parameter
Data
Name Required/Optional Description
Type
index Required int User index
Return
Return user name by index
Example
VBScript Example
TextBox0.Text = UserCmd.GetUserNameByIndex(1)
GetUserType
Get current user type
Define
GetUserType(userName)
Parameter
Data
Name Required/Optional Description
Type
userName Required String Username
Example
Get current user type
VBScript Example
TextBox0.Text = UserCmd.GetUserType("user")
Login
User login authentication
Define
Login(userName ,password)
Parameter
Data
Name Required/Optional Description
Type
userName Required String Username
password Required String User's password
Return
If login success,it will return True,otherwise return False
Example User login
VBScript Example
Call UserCmd.Login("username","password")
LoginBox
User login
Define
LoginBox()
Example User login
VBScript Example
UserCmd.LoginBox()
Logout
User logout
Define
Logout()
Example Logout
VBScript Example
UserCmd.Logout()
RemoveUser
Remove user
Define
RemoveUser(userName)
Parameter
Data
Name Required/Optional Description
Type
userName Required String Username
Return
If success,it will return True,otherwise return False
Example
Delete user called "newuser",you must have administrator privileges,
and youself cannot be deleted
VBScript Example
UserCmd.RemoveUser("newuser")
UserManagerBox
User management
Define
UserManagerBox()
Example
Pop-up "UserManager" window,display user information
VBScript Example
UserCmd.UserManagerBox()
UserName
Current username
Define
String UserName
Description
Annotation
This property is read-only
TextBox0.Text = UserCmd.UserName
RecordVariable
Variable record
Methods list
Name Description
NotifySave Inform to save the historical data
Inform to save the historical data,can
NotifySave
be forced store
Property list
Name Description
Get or set the time interval of
IntervalTime
the storage
NotifySave
Inform to save the historical data
Define
NotifySave()
Example
Inform to save the historical data
VBScript Example
Call Record.VariableRecord0.NotifySave()
NotifySave
Inform to save the historical data
Define
NotifySave(isForcedStorage)
Parameter
Data
Name Required/Optional Description
Type
Whether to forced
store,the shortest is
isForcedStorage Required Bool
trigger again per
second
Example
Inform to save the historical data
VBScript Example
Call Record.VariableRecord0.NotifySave(true)
IntervalTime
Get or set the time interval of the storage
Define
Int IntervalTime
Example
Set the variable record 0 storage time interval to 1 second
VBScript Example
Record.VariableRecord0.IntervalTime = 1
HistRecordGroup
Variable record group
Property list
Name Description
Description Discription of variable record group
Name Variable record group name
The data table name of variable record
TableName
group
Description
Description of the variable record group
Define
String Description
Description
Annotation
This property is read/write
Example
Modify the discription of the variables record group "HistoryGroup0"
to "test"
VBScript Example
HistRecord.HistoryGroup0.Description="test"
Name
The name of the variable record group
Define
String Name
Description
Annotation
This property is read only
Example
Display the name of the variable record group "HistoryGroup0"
VBScript Example
TextBox0.Text = HistRecord.HistoryGroup0.Name
TableName
The data table name of the variable record group
Define
String TableName
Description
Annotation
This property is read only
Example
Display the data table name of the variable record group
"HistoryGroup0"
VBScript Example
TextBox0.Text = HistRecord.HistoryGroup0.TableName
HistRecordItem
Variable record
Property list
Name Description
Description Description
Expression Expression
Name Name
RealColName Datatable mame
StoredValueTypeStr Value type
Description
Description of the variable record group
Define
String Description
Description
Annotation
This property is read/write
Example
Modify the discription of the "historical record 1" in variables record
group "HistoryGroup0" to "record number of products"
VBScript Example
HistRecord.HistoryGroup0.historical
record1.Description = "record number of products"
Expression
Expression
Define
String Expression
Description
nnotation
A
This property is read only
Example
Display the expression of "variable record1"
VBScript Example
TextBox0.Text =
HistRecord.HistoryGroup0.historical
record1.Expression
Name
Name
Define
String Name
Description
Annotation
This property is read only
Example
Display the name of "variable record1"
VBScript Example
TextBox0.Text =
HistRecord.HistoryGroup0.historical record1.Name
RealColName
The datatable's column name
Define
String RealColName
Description
Annotation
This property is read only
Example
Query the datatable's column name of "variable record1"
VBScript Example
TextBox0.Text =
HistRecord.HistoryGroup0.historical
record1.RealColName
StoredValueTypeStr
Value type
Define
String StoredValueTypeStr
Description
Annotation
Value type,simulation value: double,switching value: boolean,text
content: string
Example
Display the value type of "variable record1"
VBScript Example
TextBox0.Text =
HistRecord.HistoryGroup0.HistRecord1.StoredValueTypeStr
HistRecordCmd
Polygon controls
Methods list
Name Description
QueryRealTimeData Query real-time data
QueryWithStorageItemName Query history group data
QueryRealTimeData
Query real time data
Define
QueryRealTimeData(histStorageGroupName)
Parameter
Data
Name Required/Optional Description
Type
History storage group
histStorageGroupName Required String
name
Example
Get real time data of the history storage group "HistoryGroup0"
Add a "Report0" to window,display the data table in "Report0"
VBScript Example
dt =
HistRecordCmd.QueryRealTimeData("HistRecord.HistoryGroup0")
Call Report0.ClearCellContent()
Call Report0.ShowDataTableForReport(1,1,dt)
QueryWithStorageItemName
Query history storage group data
Define
QueryWithStorageItemName(histStorageGroupName , histStorageItemNames ,
startTime , endTime , rowsCount)
Parameter
Data
Name Required/Optional Description
Type
The name of variable storage
histStorageGroupName Required String group
History storage variable
histStorageItemNames Required String name,separated with commas
VBScript Example
StartTime = DateAdd("h",-1,now())
dt =
HistRecordCmd.QueryWithStorageItemName("HistoryGroup0","historical
record,historical record1",StartTime,Sys.Now,-1)
Call Report0.ClearCellContent()
Call Report0.ShowDataTableForReport(1,1,dt)
EventScript
Event script
Property list
Name Description
Description Description
Expression Expression
Interval Time interval,the unit is millisecond
IntTriggerMode Trigger mode
IsEnable Whether to enable the script
Name The name of user script
ScriptContent The script content
UniqueIdentifier The unique identifier
Description
Description
Define
String Description
Description
Annotation
This property is read/write
Example
Display the "ConditionScript" description information in a textbox
VBScript Example
TextBox0.Text = Script.ConditionScript.Description
Expression
Expression
Define
String Expression
Description
Annotation
This property is read/write
Example
Get the expression of "ConditionScript"
VBScript Example
TextBox0.Text = Script.ConditionScript.Expression
Interval
Time interval,the unit is millisecond
Define
Int32 Interval
Description
Annotation
This property is read/write
Example
Get the interval of "ConditionScript"
VBScript Example
TextBox0.Text = Script.ConditionScript.Interval
IntTriggerMode
Trigger mode
Define
IntTriggerMode
Description
Annotation
This property is read/write
Example
Get the triggermode of "ConditionScript"
VBScript Example
TextBox0.Text =
Script.ConditionScript.IntTriggerMode
IsEnable
Whether to enable the script
Define
Boolean IsEnable
Description
nnotation
A
This property is read/write
Example
Query whether the "ConditionScript" is enabled
VBScript Example
TextBox0.Text = Script.ConditionScript.IsEnable
Name
The name of user script
Define
String Name
Description
Annotation
This property is read-only
Example
Get the name of "ConditionScript"
VBScript Example
TextBox0.Text = Script.ConditionScript.Name
ScriptContent
The script content
Define
String ScriptContent
Description
Annotation
This property is read/write
Example
Get the content of "ConditionScript"
VBScript Example
TextBox0.Text =
Script.ConditionScript.ScriptContent
UniqueIdentifier
The unique identifier ID
Define
Int32 UniqueIdentifier
Description
Annotation
This property is read-only
Example
Get the unique ID of "ConditionScript"
VBScript Example
TextBox0.Text =
Script.ConditionScript.UniqueIdentifier
TimerScript
Timer script
Property list
Name Description
Description Description
EndTime The end time
Interval Time interval,the unit is millisecond
IntTriggerMode Trigger mode
IsEnable Whether to enable the script
IsEnableEndTime Whether to use the end time
The Months, separated by commas,
MonthDays
such as "1,20,22,25"
Name The name of user script
ScriptContent The content of script
StartTime Start time
UniqueIdentifier The unique identifier ID
The Weeks, separated by commas,
WeekDays such as“0,1,2,3”,0 to 6 represent from
Sunday to Saturday
Description
Description
Define
String Description
Description
Annotation
This property is read/write
Example
Display the "TimeScript" description information
VBScript Example
TextBox0.Text = Script.TimeScript.Description
EndTime
End time
Define
DateTime EndTime
Description
Annotation
This property is read/write
Example
Query the endtime information of "TimeScript"
VBScript Example
TextBox0.Text = Script.TimeScript.EndTime
Interval
Time interval,the unit is millisecond
Define
Int32 Interval
Description
Annotation
This property is read/write
Example
Query the interval of "TimeScript"
VBScript Example
TextBox0.Text = Script.TimeScript.Interval
IntTriggerMode
Trigger mode
Define
IntTriggerMode
Description
nnotation
A
This property is read/write
Example
Get the "TimeScript" triggermode
VBScript Example
TextBox0.Text = Script.TimeScript.IntTriggerMode
IsEnable
Whether to enable the script
Define
Boolean IsEnable
Description
nnotation
A
This property is read/write
Example
Query whether the "TimeScript" is enabled
VBScript Example
TextBox0.Text = Script.TimeScript.IsEnable
IsEnableEndTime
Whether to use the end time
Define
Boolean IsEnableEndTime
Description
Annotation
This property is read/write
Example
Query whether the "TimeScript" use endtime
VBScript Example
TextBox0.Text = Script.TimeScript.IsEnableEndTime
MonthDays
The Months, separated by commas, such as "1,20,22,25"
Define
String MonthDays
Description
Annotation
This property is read/write
Example
Query the months of "TimeScript"
VBScript Example
TextBox0.Text = Script.TimeScript.MonthDays
Name
The name of user script
Define
String Name
Description
Annotation
This property is read-only
Example
Get the name of "TimeScript"
VBScript Example
TextBox0.Text = Script.TimeScript.Name
ScriptContent
The script content
Define
String ScriptContent
Description
Annotation
This property is read/write
Example
Get the content of "TimeScript"
VBScript Example
TextBox0.Text = Script.TimeScript.ScriptContent
StartTime
Start time
Define
DateTime StartTime
Description
Annotation
This property is read/write
Example
Get the start time of "TimeScript"
VBScript Example
TextBox0.Text = Script.TimeScript.StartTime
UniqueIdentifier
The unique identifier ID
Define
Int32 UniqueIdentifier
Description
nnotation
A
This property is read-only
Example
Get the unique ID of "TimeScript"
VBScript Example
TextBox0.Text = Script.TimeScript.UniqueIdentifier
WeekDays
The Weeks, separated by commas,such as“0,1,2,3”,0 to 6
represent from Sunday to Saturday
Define
String WeekDays
Description
Annotation
This property is read/write
Example
Query the weeks of "TimeScript"
VBScript Example
TextBox0.Text = Script.TimeScript.WeekDays
ScriptCmd
Save user script
Methods list
Name Description
Save Save user script
Save
Save user script
Define
Save()
Example
Save user script
VBScript Example
Call ScriptCmd.Save()
Recipe
Recipe
Property list
Name Description
CurrentRecipeItem Current recipe item
Description Description
CurrentRecipeItem
Current recipe item
Define
String CurrentRecipeItem
Description
Annotation
This property is read-only
TextBox0.Text = Recipe.Recipe.CurrentRecipeItem
Description
Description
Define
String Description
Description
Annotation
This property is read/write
Recipe.Drink.Description = "AppleDrink"
TextBox0.Text = Recipe.Drink.Description
RecipeCmd
Recipe command
Methods list
Name Description
AddRecipe Add recipe
AddRecipeElement Add recipe ingredient
AddRecipeItem Add recipe item
ExportRecipeToExcel Export the recipe to Excel
GetCurrentRecipeItem Get current recipe item
GetRecipeElementList Get recipe element list
GetRecipeItemList Get recipe item list
Get the value of ingredient which
GetRecipeItemValue
specified by the recipe item
GetRecipeNameList Get recipe name list
Export the excel to the specified
recipe,if the recipe do not
ImportRecipeFromExcel
exist,add a new recipe and
import
LoadRecipeItem Load the recipe item to variable
RemoveRecipe Remove recipe
RemoveRecipeElement Remove the ingredient of recipe
RemoveRecipeItem Remove the recipe item
SaveToRecipeItem Save the variable to recipe item
Set the ingredient value which
SetRecipeItemValue
specified by the recipe item
AddRecipe
Add recipe
Define
AddRecipe(recipeName ,description)
Parameter
Data
Name Required/Optional Description
Type
recipeName Required String Recipe name
description Required String Description
Example
Add two TextBox to window,"TextBox0" and "TextBox1",record the
recipe name and recipe description respectively.Add recipe,get the
content of "TextBox0" and "TextBox1" as recipe name and
description.
VBScript Example
Call RecipeCmd.AddRecipe(
"TextBox0.Text,TextBox1.Text")
AddRecipeElement
Add recipe ingredient
Define
AddRecipeElement(recipeName ,recipeElementName ,description)
Parameter
Data
Name Required/Optional Description
Type
recipeName Required String Recipe name
recipeElementName Required String Recipe ingredients name
description Required String Description of recipe ingredients
Example
Add three TextBox to window,"TextBox0" , "TextBox1" and "TextBox2",record the recipe
name,element name and recipe description respectively.Add recipe,get the content of
"TextBox0" , "TextBox1" and "TextBox2" as recipe name,element name and description.
VBScript Example
Call
RecipeCmd.AddRecipeElement(TextBox0.Text,TextBox1.Text,TextBox2.Text)
AddRecipeItem
Add recipe item
Define
AddRecipeItem(recipeName ,recipeItemName ,description)
Parameter
Data
Name Required/Optional Description
Type
recipeName Required String Recipe name
recipeItemName Required String Recipe item name
description Required String Description of recipe ingredients
Example
Add three TextBox to window,"TextBox0" , "TextBox1" and "TextBox2",record the recipe
name,recipe item name and recipe item description respectively.Add recipe item,get the
content of "TextBox0" , "TextBox1" and "TextBox2" as recipe name,recipe item name and
recipe item description.
VBScript Example
Call
RecipeCmd.AddRecipeItem(TextBox0.Text,TextBox1.Text,TextBox2.Text)
ExportRecipeToExcel
Export the recipe to Excel
Define
ExportRecipeToExcel(recipeName ,filePath ,excelVersion)
Parameter
Data
Name Required/Optional Description
Type
recipeName Required String Recipe name
filePath Required String The file path to export the Excel
Excel version,value range:Excel 97 to 2003,Excel
excelVersion Required String
2007,Excel2010,Excel2013
Return
If export success, it will return True
Example
Add three TextBox to window,"TextBox0" , "TextBox1" and "TextBox2",record the recipe
name,export file path and excel version respectively.Export the recipe to excel,get the content of
"TextBox0" , "TextBox1" and "TextBox2" as recipe name,export file path and excel version.
VBScript Example
Call
RecipeCmd.ExportRecipeToExcel(TextBox0.Text,TextBox1.Text,TextBox2.Text)
GetCurrentRecipeItem
Get current recipe item
Define
GetCurrentRecipeItem(recipeName)
Parameter
Data
Name Required/Optional Description
Type
recipeName Required String Recipe name
Return
The current recipe item,if does not exist,return an empty string
Example
Specify recipe name in "ComboBox0",get current recipe item.
VBScript Example
TextBox0.Text =
RecipeCmd.GetCurrentRecipeItem(ComboBox0.Text)
GetRecipeElementList
Get recipe element list
Define
GetRecipeElementList(recipeName)
Parameter
Data
Name Required/Optional Description
Type
recipeName Required String Recipe name
Return
Return recipe element list
Example Get recipe element list of "cake" and display through
ComboBox
VBScript Example
tt = RecipeCmd.GetRecipeElementList("cake")
ComboBox1.ClearItems()
ComboBox1.AddItems(tt)
GetRecipeItemList
Get recipe item list
Define
GetRecipeItemList(recipeName)
Parameter
Data
Name Required/Optional Description
Type
recipeName Required String Recipe name
Return
Recipe item list
Example
Get recipe item list of "cake" and display through ComboBox
VBScript Example
tt = RecipeCmd.GetRecipeItemList("cake")
ComboBox1.ClearItems()
ComboBox1.AddItems(tt)
GetRecipeItemValue
Get the ingredient value which specified by the recipe item
Define
GetRecipeItemValue(recipeName ,recipeItemName ,recipeElementName)
Parameter
Data
Name Required/Optional Description
Type
recipeName Required String Recipe name
recipeItemName Required String Recipe item name
recipeElementName Required String Recipe element name
Return
Return specified element values,if get fail,return null
Example
Get the value of specified element,ComboBox1,ComboBox2,ComboBox3 are used to specify recipe
name,recipe item name and recipe element name.
VBScript Example
Call
RecipeCmd.GetRecipeItemValue(ComboBox1.Text,ComboBox2.Text,ComboBox3.Text)
GetRecipeNameList
Get recipe name list
Define
GetRecipeNameList()
Return
Recipe name list
Example
Get recipe name list and display through ComboBox
VBScript Example
tt = RecipeCmd.GetRecipeNameList()
ComboBox1.ClearItems()
ComboBox1.AddItems(tt)
ImportRecipeFromExcel
Export the excel to the specified recipe, if the recipe do not exist, add a new recipe and import
Define
ImportRecipeFromExcel(filePath ,recipeName ,excelVersion)
Parameter
Data
Name Required/Optional Description
Type
filePath Required String The file path of Excel
recipeName Required String Recipe name
Excel version, value range:Excel97to2003,
excelVersion Required String
Excel2007,Excel2010,Excel2013
Return
If import success, it will return True, otherwise return False
Example
Add three TextBox to window,"TextBox0" , "TextBox1" and "TextBox2",record import file path,recipe
name and excel version respectively.Import recipe from excel,get the content of "TextBox0" ,
"TextBox1" and "TextBox2" as import file path,recipe name and excel version.
VBScript Example
Call
RecipeCmd.ImportRecipeFromExcel(TextBox0.Text,TextBox1.Text,TextBox2.Text)
LoadRecipeItem
Load the recipe item to variable
Define
LoadRecipeItem(recipeName ,recipeItemName)
Parameter
Data
Name Required/Optional Description
Type
recipeName Required String Recipe name
recipeItemName Required String Recipe items name
Example
Load recipe item to variable,"ComboBox1" and "ComboBox2" are used to
spesify recipe name and recipe item name.
VBScript Example
Call
RecipeCmd.LoadRecipeItem(ComboBox1.Text,ComboBox2.Text)
RemoveRecipe
Remove the recipe
Define
RemoveRecipe(recipeName)
Parameter
Data
Name Required/Optional Description
Type
recipeName Required String The recipe name
Call RecipeCmd.RemoveRecipe("cake")
RemoveRecipeElement
Remove the ingredient of recipe
Define
RemoveRecipeElement(recipeName ,recipeElementName)
Parameter
Data
Name Required/Optional Description
Type
recipeName Required String The recipe name
recipeElementName Required String The recipe element name
Example
Delete recipe element,"ComboBox1" and "ComboBox2" are used to spesify
recipe name and recipe element name.
VBScript Example
Call
RecipeCmd.RemoveRecipeElement(ComboBox1.Text,ComboBox2.Text)
RemoveRecipeItem
Delete the recipe item
Define
RemoveRecipeItem(recipeName ,recipeItemName)
Parameter
Data
Name Required/Optional Description
Type
recipeName Required String The recipe name
recipeItemName Required String The recipe item name
Example
Delete recipe item,"ComboBox1" and "ComboBox2" are used to spesify
recipe name and recipe item name.
VBScript Example
Call
RecipeCmd.RemoveRecipeItem(ComboBox1.Text,ComboBox2.Text)
SaveToRecipeItem
Save the variable to recipe item
Define
SaveToRecipeItem(recipeName ,recipeItemName)
Parameter
Data
Name Required/Optional Description
Type
recipeName Required String The recipe name
recipeItemName Required String The recipe item name
Example
Save to recipe item,"ComboBox1" and "ComboBox2" are used to spesify
recipe name and recipe item name.
VBScript Example
Call
RecipeCmd.SaveToRecipeItem(ComboBox1.Text,ComboBox2.Text)
SetRecipeItemValue
Set the ingredient value which specified by the recipe item
Define
SetRecipeItemValue(recipeName ,recipeItemName ,recipeElementName ,value)
Parameter
VBScript Example
Call
RecipeCmd.SetRecipeItemValue(ComboBox1.Text,ComboBox2.Text,ComboBox3.Text,Text
RecipeElement
Recipe ingredient
Property list
Name Description
Description Description
Name The name of recipe ingredient
The absolute path of recipe ingredients
VariablePath
associated variables
Description
Description
Define
String Description
Description
Annotation
This property is read/write
Recipe.Recipe.RecipeElement1.Description =
"NewRecipeElement"
Name
The name of new recipe ingredient
Define
String Name
Description
Annotation
This property is read-only
TextBox0.Text = Recipe.Recipe.RecipeElement1.Name
VariablePath
The absolute path of recipe ingredients associated variables
Define
String VariablePath
Description
nnotation
A
This property is read-write
Example
Modify the recipe element of "RecipeElement4" associated variables
to "Var.NewVariableGroup.NewVariable"
VBScript Example
Recipe.Recipe.RecipeElement4.VariablePath =
Var.NewVariableGroup.NewVariable
RecipeItem
The recipe ingredients value group
Property list
Name Description
Description Description
Name Recipe items name
Description
Description
Define
String Description
Description
Annotation
This property is read-write
Example
Modify the description of the recipe item "RecipeItem2" to
"NewRecipeItem"
VBScript Example
Recipe.Recipe.RecipeItem2.Description =
"NewRecipeItem"
Name
Recipe items name
Define
String Name
Description
Annotation
This property is read-only
TextBox0.Text = Recipe.Recipe.RecipeItem2.Name
DbAccess
Database access
Methods list
Name Description
Check whether there is a
CheckTableIsExisted specified name in the database
tables
Execute sql statement and
ExecuteDataTable
returns the query table
Execute sql statement and
ExecuteNonQuery
return the affected rows
Execute sql statement and
ExecuteScalar returns the query table, return
the first line in the first column
Access the number of rows in
GetDataSourceRowsCount
the table of data sources
GetEmptyTable Get empty tables
GetPageNum Get the number of pages
Get the table(If the paging,
GetTable access the table of the last
page)
Get the table according to the
GetTable
number of pages
SaveTable Save the table
Save the table(Save the
SaveTable
specified column)
TestConnection Test the database connection
Property list
Name Description
ConnectionString Database connection string
Description Description
IsPaging Whether to paging
MaxPagingCount Display the maximum rows of the table
Name Name of the database access
Show the Provider of database
Provider
connection, that is, the database type
TableName The name of the data table
UniqueIdentifier The unique identification ID
CheckTableIsExisted
Check whether there is a specified table in the database
Define
CheckTableIsExisted(tableName)
Parameter
Data
Name Required/Optional Description
Type
Name of the database
tableName Required String
access
Example
Check whether there is a database table named "newtable"
VBScript Example
TextBox0.Text =
DbAccess.DatabaseAccess.CheckTableIsExisted("newtable")
ExecuteDataTable
Execute sql statement and returns the query table
Define
ExecuteDataTable(sql)
Parameter
Name Required/Optional Data Type Description
sql Required String sql statement
Example
Executing SQL statements to get the data of "DatabaseAccess" with
ID 1,returns the query table and display in the Report0 control
VBScript Example
dim sql
sql = "SELECT * FROM " +
DbAccess.DatabaseAccess.TableName + " where "+
DbAccess.DatabaseAccess.TableName +".Id = 1"
dt = DbAccess.DatabaseAccess.ExecuteDataTable(sql)
Call Report0.ClearCellContent()
Call Report0.ShowDataTableForReport(1,1,dt)
ExecuteNonQuery
Execute sql statement and return the affected rows
Define
ExecuteNonQuery(sql)
Parameter
Name Required/Optional Data Type Description
sql Required String sql statement
Example
Execute sql statement to modify the name of
"DatabaseAccess",return the affected rows
VBScript Example
dim sql
sql = "UPDATE " +
DbAccess.DatabaseAccess.TableName +" SET
[name]='titi' where Id = 1"
TextBox0.Text =
DbAccess.DatabaseAccess.ExecuteNonQuery(sql)
ExecuteScalar
Execute sql statement , return the first line in the first column of table
Define
ExecuteScalar(sql)
Parameter
Name Required/Optional Data Type Description
sql Required String sql statement
Example
Execute sql statement to query the data of the top 50 lines in
"DatabaseAccess",return the first line in the first column
VBScript Example
dim sql
sql = "Select NAME,AGE From " +
DbAccess.DatabaseAccess.TableName
TextBox0.Text =
DbAccess.DatabaseAccess.ExecuteScalar(sql)
GetDataSourceRowsCount
Get the number of rows in the table of data sources
Define
GetDataSourceRowsCount()
Example
Get the number of rows in the table of data sources
VBScript Example
TextBox0.Text =
DbAccess.DatabaseAccess.GetDataSourceRowsCount()
GetEmptyTable
Get empty tables
Define
GetEmptyTable()
Example
Get the table headers of "DatabaseAccess",and display it in the
report control
VBScript Example
dt = DbAccess.DatabaseAccess.GetEmptyTable()
Call Report0.ClearCellContent()
Call Report0.ShowDataTableForReport(1,1,dt)
GetPageNum
Get the number of pages
Define
GetPageNum()
Example
Get the number of pages
VBScript Example
Button0.Content =
DbAccess.DatabaseAccess.GetPageNum()
GetTable
Get the table(If the paging, access the table of the last page)
Define
GetTable()
Example
Get the table
VBScript Example
dt = DbAccess.DatabaseAccess.GetTable()
Call Report0.ClearCellContent()
Call Report0.ShowDataTableForReport(1,1,dt)
GetTable
Get the table according to the number of pages
Define
GetTable(pageNum)
Parameter
Name Required/Optional Data Type Description
pageNum Required Int The number of pages
Example
Read the data of the second page
VBScript Example
dt = DbAccess.DatabaseAccess.GetTable(2)
Call Report0.ClearCellContent()
Call Report0.ShowDataTableForReport(1,1,dt)
SaveTable
Save the table
Define
SaveTable(dt)
Parameter
Name Required/Optional Data Type Description
dt Required DataTable The data source
Example
Save the table
VBScript Example
dt = DbAccess.DatabaseAccess.GetTable()
row = dt.NewRow()
row("name") = "Lucy"
row("age") = 21
Call dt.Rows.Add(row)
DbAccess.DatabaseAccess.SaveTable(dt)
SaveTable
Save the table
Define
SaveTable(dt , columnStr)
Parameter
VBScript Example
dt = Report0.GetReportDataTable(0)
dt.TableName = DbAccess.DatabaseAccess.TableName
Text0.Text =
DbAccess.DatabaseAccess.SaveTable(dt,"Id,name")'Update
the specified column and return the number of rows
that have been updated
TestConnection
Test the database connection
Define
TestConnection()
Example
Test the database connection,True is connected, false is not
connected
VBScript Example
Text0.Text =
DbAccess.DatabaseAccess.TestConnection()
ConnectionString
Database connection string
Define
String ConnectionString
Description
Annotation
This property is read-only
Example
Display the string of the "DatabaseAccess"
VBScript Example
Text0.Text =
DbAccess.DatabaseAccess.ConnectionString
Description
Description
Define
String Description
Description
Annotation
This property is read/write
Example
Modify the description of the "DatabaseAccess"
VBScript Example
DbAccess.DatabaseAccess.Description = "Custom
database tables"
IsPaging
Whether to paging
Define
String IsPaging
Description
Annotation
This property is read/write
Example
Modify the "DatabaseAccess" to paging
VBScript Example
DbAccess.DatabaseAccess.IsPaging = True
MaxPagingCount
Display the maximum rows of the table
Define
String MaxPagingCount
Description
Annotation
This property is read/write,the default value is 50
Example
Modify the maximum rows of the "DatabaseAccess"
VBScript Example
DbAccess.DatabaseAccess.MaxPagingCount = 20
Name
Name of the database access
Define
String Name
Description
Annotation
This property is read-only
Example
Display the name of “DatabaseAccess”
VBScript Example
Text0.Text = DbAccess.DatabaseAccess.Name
Provider
Show the Provider of database connection, that is, the database type
Define
String Provider
Description
Annotation
This property is read-only
Example
Display the database type of "DatabaseAccess"
VBScript Example
Text0.Text = DbAccess.DatabaseAccess.Provider
TableName
The name of the data table
Define
String TableName
Description
Annotation
This property is read-only
Example
Pop-up a dialog to display the data table name of the
"DatabaseAccess"
VBScript Example
MsgBox DbAccess.DatabaseAccess.TableName
UniqueIdentifier
The unique identification ID
Define
String UniqueIdentifier
Description
Annotation
This property is read-only
Example
Display the ID of the "DatabaseAccess"
VBScript Example
Text0.Text =
DbAccess.DatabaseAccess.UniqueIdentifier
DbAccessCmd
Database access command
Methods list
Name Description
AddColumn Add column
CreateTable Create table
ExecuteBatchInsertData Insert to the data table
Check whether there is a
specified name of the
ExecuteCheckTableIsExisted
database table in the
database
Created the same structure
tables in the database table
ExecuteCreateDatabaseTable
according to the table
provided
Return the number of
ExecuteCreateSave
affected rows
Execute commands,return
ExecuteDataTable
the queried data table
Delete the specified data
ExecuteDropDatabaseTable
from the database
Read the first "count" lines of
ExecuteGetTable
data
Execute commands,return
ExecuteNonQuery
the number of affected rows
Extract data from the
DataTable to perform
ExecuteNonQueryDT
operations according to the
parameters (@ as markup)
Select column to save,
ExecuteSave return the number of
affected rows
Execute commands,return
ExecuteScalar
the number of affected rows
SelectDT Select according to the
specified order
SetPrimary Set the primary key
AddColumn
Add columns
Define
AddColumn(dt , name , caption , dataType , maxLength , isAllowNull , isAutoIncrement , isUnique)
Parameter
dim dt
dt = DbAccessCmd.CreateTable("newtable") 'Create the database table" newtable"
Call DbAccessCmd.AddColumn(dt,"Id","id",1,500,false,true,true) 'Add columns
Call DbAccessCmd.AddColumn(dt,"name",name",4,500,false,false,false)
Call DbAccessCmd.AddColumn(dt,"age","age",1,500,false,false,false)
Call DbAccessCmd.SetPrimary(dt,"Id") 'Set primary key
cc =
DbAccessCmd.ExecuteCreateDatabaseTable("DbAccess.DatabaseAccess","sqlservercom
MsgBox cc 'whether created successfully
CreateTable
Create table
Define
CreateTable(tableName)
Parameter
dim dt
dt = DbAccessCmd.CreateTable("newtable") 'Create the database table" newtable"
Call DbAccessCmd.AddColumn(dt,"Id","id",1,500,false,true,true) 'Add columns
Call DbAccessCmd.AddColumn(dt,"name",name",4,500,false,false,false)
Call DbAccessCmd.AddColumn(dt,"age","age",1,500,false,false,false)
Call DbAccessCmd.SetPrimary(dt,"Id") 'Set primary key
cc =
DbAccessCmd.ExecuteCreateDatabaseTable("DbAccess.DatabaseAccess","sqlservercom
MsgBox cc 'whether created successfully
ExecuteBatchInsertData
Insert to the data table
Define
ExecuteBatchInsertData(connInfo , providerName , dt)
Parameter
VBScript Example
dim dt dt = DbAccess.DatabaseAccess.GetTable()
dt(0)("name") = "mary"
dt(0)("age") = 18
Call
DbAccessCmd.ExecuteBatchInsertData("DbAccess.DatabaseAccess","sqlservercompact
Call Report0.ShowDataTableForReport(1,1,dt)
ExecuteCheckTableIsExisted
Check whether there is a specified name of the database table in the database
Define
ExecuteCheckTableIsExisted(connInfo , providerName , tableName)
Parameter
Data
Name Required/Optional Description
Type
connInfo Required String Database Access Table
Database type(sqlserver,sqlservercompact,
providerName Required String
oracle)
tableName Required String Table name
Example
Check whether there is a database table called "newtable" in the database
VBScript Example
Text0.Text =
DbAccessCmd.ExecuteCheckTableIsExisted("DbAccess.DatabaseAccess","sqlservercom
ExecuteCreateDatabaseTable
Create the same structure tables in the database table according to the table provided
Define
ExecuteCreateDatabaseTable(connInfo , providerName , dt , otherParameter)
Parameter
dim dt
dt = DbAccessCmd.CreateTable("newtable") 'Create the database table" newtable"
Call DbAccessCmd.AddColumn(dt,"Id","id",1,500,false,true,true) 'Add columns
Call DbAccessCmd.AddColumn(dt,"name",name",4,500,false,false,false)
Call DbAccessCmd.AddColumn(dt,"age","age",1,500,false,false,false)
Call DbAccessCmd.SetPrimary(dt,"Id") 'Set primary key
cc =
DbAccessCmd.ExecuteCreateDatabaseTable("DbAccess.DatabaseAccess","sqlservercom
MsgBox cc 'whether created successfully
ExecuteCreateSave
Return the number of affected rows(If there is not exist in the database,create the same structure
tables in the database table according to the table provided,save it)
Define
ExecuteCreateSave(connInfo , providerName , dt)
Parameter
Dim dt
dt = Report0.GetReportDataTable(Id)
dt.tableName = DbAccess.DatabaseAccess.TableName
tt =
DbAccessCmd.ExecuteCreateSave("DbAccess.DatabaseAccess","sqlservercompact",dt
MsgBox tt
ExecuteDataTable
Execute commands, return the queried data table
Define
ExecuteDataTable(connInfo , providerName , sql)
Parameter
Data
Name Required/Optional Description
Type
connInfo Required String Database Access Table
Database type(sqlserver,sqlservercompact,
providerName Required String
oracle)
sql Required String sql statements
Example
SQL statement to query the same ID 1 data in the "DatabaseAccess" and " DatabaseAccess1 ", and
returns, shown in the report controls
VBScript Example
dim sql
sql = "SELECT * FROM " + DbAccess.DatabaseAccess.TableName + " where "+
DbAccess.DatabaseAccess.TableName +".Id = 1"
dt =
DbAccessCmd.ExecuteDataTable("DbAccess.DatabaseAccess","sqlservercompact",sql
Call Report0.ShowDataTableForReport(1,1,dt)
ExecuteDropDatabaseTable
Delete the specified data from the database
Define
ExecuteDropDatabaseTable(connInfo , providerName , tableName)
Parameter
Data
Name Required/Optional Description
Type
connInfo Required String Database Access Table
Database type(sqlserver,sqlservercompact,
providerName Required String
oracle)
tableName Required String Table name
Example
Delete the corresponding database table in“DatabaseAccess”
VBScript Example
Text0.Text =
DbAccessCmd.ExecuteDropDatabaseTable("DbAccess.DatabaseAccess","sqlservercompa
ExecuteGetTable
Read the first "count" rows of data
Define
ExecuteGetTable(connInfo , providerName , tableName , count)
Parameter
Data
Name Required/Optional Description
Type
connInfo Required String Database Access Table
providerName Required String Database type(sqlserver,sqlservercompact,oracle)
tableName Required String Table name
The number of rows(If negative, read the latest count the
count Required String
data, if is zero, read the empty table)
Example
Read the first 3 rows of data in the database,and shown in the report controls
VBScript Example
dt =
DbAccessCmd.ExecuteGetTable("DbAccess.DatabaseAccess","sqlservercompact","newt
Call Report0.ShowDataTableForReport(1,1,dt)
ExecuteNonQuery
Execute commands, return the number of affected rows
Define
ExecuteNonQuery(connInfo , providerName , sql)
Parameter
Data
Name Required/Optional Description
Type
connInfo Required String Database Access Table
Database type(sqlserver,sqlservercompact,
providerName Required String
oracle)
sql Required String sql statements
Example
SQL statements update the ID 1 name to "titi" in the "DatabaseAccess",return and shown it in the report
controls
VBScript Example
dim sql
sql = "UPDATE " + DbAccess.DatabaseAccess.TableName +" SET NAME = 'titi'
where Id = 1"
Call
DbAccessCmd.ExecuteNonQuery("DbAccess.DatabaseAccess","sqlservercompact",sql)
dt = DbAccess.DatabaseAccess.GetTable()
Call Report0.ClearCellContent()
Call Report0.ShowDataTableForReport(1,1,dt)
ExecuteNonQueryDT
Extract data from the DataTable to perform operations according to the parameters (@ as markup),for
example:update table set Name=@Name,Age=@Age where Id=@Id
Define
ExecuteNonQueryDT(connInfo , providerName , sql)
Parameter
Data
Name Required/Optional Description
Type
connInfo Required String Database Access Table
Database type(sqlserver,sqlservercompact,
providerName Required String
oracle)
sql Required String sql statements
Example
VBScript Example
dt = Report0.GetReportDataTable(0)
sql = "update NewTable set Name=@Name,Age=@Age where Id=@Id"
Call
DbAccessCmd.ExecuteNonQueryDT("DbAccess.DatabaseAccess","sqlservercompact",dt
dt1 = DbAccess.DatabaseAccess.GetTable("NewTable")
Call Report0.ShowDataTableForReport(1,1,dt1)
ExecuteSave
Select column to save, return the number of affected rows
Define
ExecuteSave(connInfo , providerName , dt , columnNames)
Parameter
dt = Report0.GetReportDataTable(0)
dt.tableName = DbAccess.DatabaseAccess.TableName
tt =
DbAccessCmd.ExecuteSave("DbAccess.DatabaseAccess","sqlservercompact",dt,"Id,na
MsgBox tt
ExecuteScalar
Execute commands, return the number of affected rows
Define
ExecuteScalar(connInfo , providerName , sql)
Parameter
Data
Name Required/Optional Description
Type
connInfo Required String Database Access Table
Database type(sqlserver,sqlservercompact,
providerName Required String
oracle)
sql Required String sql statements
Example
Execute sql statement to query the data of the top 50 lines in "DatabaseAccess",return and show the
first line in the first column in the report controls
VBScript Example
dim sql
sql = "Select Top 50 [name],[age] From " +
DbAccess.DatabaseAccess.TableName
tt =
DbAccessCmd.ExecuteScalar("DbAccess.DatabaseAccess","sqlservercompact",sql)
Call Report0.SetCellValue(tt,1,1)
SelectDT
Select according to the specified order
Define
SelectDT(dt , filter , sort)
Parameter
Name Required/Optional Data Type Description
dt Required DataTable Data source
Filter condition(for
filter Required String
example:id<10)
Sorting conditions(for
example:desc is
sort Required String
descending, the default is
ascending)
Example
Obtain the data in "DatabaseAccess", and show in report controls
after sorted according to the requirements
VBScript Example
dt = DbAccess.DatabaseAccess.GetTable()
cc = DbAccessCmd.SelectDT(dt,"Id<=10","Id desc")
Call Report0.ShowDataTableForReport(1,1,cc)
SetPrimary
Set the primary key
Define
SetPrimary(dt , key)
Parameter
dim dt
dt = DbAccessCmd.CreateTable("newtable") 'Create the database table" newtable"
Call DbAccessCmd.AddColumn(dt,"Id","id",1,500,false,true,true) 'Add columns
Call DbAccessCmd.AddColumn(dt,"name",name",4,500,false,false,false)
Call DbAccessCmd.AddColumn(dt,"age","age",1,500,false,false,false)
Call DbAccessCmd.SetPrimary(dt,"Id") 'Set primary key
cc =
DbAccessCmd.ExecuteCreateDatabaseTable("DbAccess.DatabaseAccess","sqlservercom
MsgBox cc 'whether created successfully
Colors
Color commands
Methods list
Name Description
ColorSelectionBox Color selector
ImageColor Image brush
LinearGradientColor Linear color
LinearGradientColor Linear color
LinearGradientColor Linear color
RadialGradientColor Radial color
RadialGradientColor Radial color
SolidColor Solid color
ColorSelectionBox
Color selector
Description
In the tree directory on the right side of the script editor, click the
"ColorSelectionBox" script node, and the "Color Choices" window
will appear, as shown in the figure below:
ImageColor
Image brush
Define
ImageColor(source , location)
Parameter
Data
Name Required/Optional Description
type
source Required String Image source path
Image location(0:Default;
location Optional Int
1:Tiled; 2: Middle; 3:Stretch)
Example
Rectangle0 is filled with a picture, and the image source path is
"\Image\Penguins.jpg",the filled method is tiled.
VBScript Example
Rectangle0.Fill =
Colors.ImageColor("\Image\Penguins.jpg",1)
User can also use the script "ColorSelectionBox" to call out the“Color
Choices” to achieve Image filling.
LinearGradientColor
Linear color
Define
LinearGradientColor(colorstring)
Parameter
Data
Name Required/Optional Description
type
A string concatendated by a combination of
colorstring Required String
groups of color and offset values
Example
Rectangle0 is filled with linear color.
VBScript Example
Rectangle0.Fill =
Colors.LinearGradientColor("#FFFF8080,0;#FFC1FFFF,0.5;#FFFF8080,1;")
User can also use the script "ColorSelectionBox" to call out the“Color Choices” to achieve
linear color filling.
LinearGradientColor
Linear color
Define
LinearGradientColor(startcolor , endcolor , angle)
Parameter
Data
Name Required/Optional Description
type
startcolor Required Brush Start color
endcolor Required Brush End color
angle Required Double Gradient angle
Example
Rectangle0 is filled with linear color.
VBScript Example
Rectangle0.Fill =
Colors.LinearGradientColor(Colors.Violet,Colors.LightGreen,45)
User can also use the script "ColorSelectionBox" to call out the“Color Choices” to
achieve linear color filling.
LinearGradientColor
Linear color
Define
LinearGradientColor(startcolorstring , endcolorstring , angle)
Parameter
Data
Name Required/Optional Description
type
startcolorstring Required String Start color string
endcolorstring Required String End color string
angle Required Double Gradient angle
Example
Rectangle0 is filled with linear color.
VBScript Example
Rectangle0.Fill =
Colors.LinearGradientColor("#FFFF80FF","#FF80FFFF",45)
User can also use the script "ColorSelectionBox" to call out the“Color
Choices” to achieve linear color filling.
RadialGradientColor
Radial color
Define
RadialGradientColor(colorstring)
Parameter
Data
Name Required/Optional Description
type
A string concatendated by a combination of
colorstring Required String
groups of color and offset values
Example
Rectangle0 is filled with radial color.
VBScript Example
Rectangle0.Fill =
Colors.RadialGradientColor("#FFFFFFFF,0;#FFFFFFFF,0;#FF000000,1;")
User can also use the script "ColorSelectionBox" to call out the“Color Choices” to achieve
radial color filling.
RadialGradientColor
Radial color
Define
RadialGradientColor(startcolorstring , endcolorstring)
Parameter
Data
Name Required/Optional Description
type
startcolorstring Required String Start color string
endcolorstring Required String End color string
Example
Rectangle0 is filled with radial color.
VBScript Example
Rectangle0.Fill =
Colors.RadialGradientColor("#FFFF0000","#FF00FF00")
User can also use the script "ColorSelectionBox" to call out the“Color
Choices” to achieve radial color filling.
SolidColor
Solid color
Define
SolidColor(colorstring)
Parameter
Data
Name Required/Optional Description
type
colorstring Required String Color string
Example
Rectangle0 is filled with solid color.
VBScript Example
Rectangle0.Fill = Colors.SolidColor("#FFFF0000")
User can also use the script "ColorSelectionBox" to call out the“Color
Choices” to achieve solid color filling.
LanguageCmd
LanguageCmd
Methods list
Name Description
Get the name of the current
GetCurrentLanguageName
language
Get the names of all
GetLanguageNames
configured languages
Get the value of the resource
GetValueByResourceName
by the resource name
Switch the current language
SwitchLanguageTo
to the specified language
GetCurrentLanguageName
Get the name of the current language
Define
GetCurrentLanguageName()
Example
Get the name of the current language
VBScript Example
Label0.Text = Languagecmd.GetCurrentLanguageName()
GetLanguageNames
Get the names of all configured languages
Define
GetLanguageNames()
Example
Get the names of all configured languages
VBScript Example
Label1.Text = LanguageCmd.GetLanguageNames()
GetValueByResourceName
Get the value of the resource by the resource name
Define
GetValueByResourceName(resname , lang)
Parameter
Data
Name Required/Optional Description
type
resname Required String Resource name
Specify the system
language name(empty
lang Optional String
string automatically uses
the current language)
Example
Query “String1” repository to display the corresponding text in the
current language
VBScript Example
Label1.Text =
LanguageCmd.GetValueByResourceName("String1","")
SwitchLanguageTo
Switch the current language to the specified language
Define
SwitchLanguageTo(language)
Parameter
Data
Name Required/Optional Description
type
Specify the
language Required String
language name
Example
Switch the current language to English
VBScript Example
LanguageCmd.SwitchLanguageTo("en")