|
Add a pen.
syntax
AddPen(
title,
unit,
color,
dataType,
protType,
low,
high,
displayLow,
displayHigh,
dataSource
)
Parameters
title
|
|
Type:
|
character
|
|
The title (displayed center left).
|
unit
|
|
Type:
|
character
|
|
Units (displayed center left with the title).
|
color
|
|
Type:
|
Colored letters
|
|
The color of the graph lines. Specifying "default" will automatically set the optimal color.
|
dataType
|
|
Type:
|
character
|
|
Data type. Depending on the type of data, specify the following data types.
"boolean"
|
Handling bit data
|
"analog"
|
Handling Numeric Data
|
"enumeration"
|
The decimal places are rounded off and the data is treated as an integer.
|
|
plotType
|
|
Type:
|
character
|
|
Plot type. Specify the plot type according to the type of plot to be displayed.
"periodic"
|
The plot points are connected to form a graph line.
|
"changebased"
|
The graph line is drawn in a stepped pattern. For bits, this type is usually selected.
|
"bar"
|
A vertical bar graph is drawn.
|
"colorbar"
|
A colored strip bar is drawn depending on the data value.
|
|
low
|
|
Type:
|
Number
|
|
The minimum value of the data. Data below the minimum value will not be displayed.
|
high
|
|
Type:
|
Number
|
|
The maximum value of the data. Data larger than the maximum value will not be displayed.
|
displayLow
|
|
Type:
|
Number
|
|
The bottom position of the display range. Specify a value between 0 and 100. The display range indicates where on the graph the top and bottom positions of the Y axis are located, expressed as a percentage. For example, if you set the display range start to 20% and the display range end to 40%, the graph will be drawn within the graph area from 20% to 40% from the bottom of the grid.
|
displayHigh
|
|
Type:
|
Number
|
|
The top position of the display range. Specify a value from 0 to 100.
|
dataSource
|
|
Type:
|
character
|
|
Specify the data source set in Historical data server. For example, "A01.F02" indicates the F02 field of the Historical data serverA01 action. You can display data from different Historical data server in one graph. For example, you can display A01.F01 and A02.F01 together.
|
Return Value
|
|
Type:
|
Boolean
|
|
FALSE - Failure. TRUE - Success.
|
Explanation
There is no limit to the number of pens you can add. However, please note that displaying too many pens at once will slow down the app.
Added pens are assigned pen numbers in sequence starting from 1. For example, the first pen you add will be numbered 1, and the eighth pen you add will be numbered 8.
|
reference
AddPen
InsertPen
DelPen
ClearPen
SelectPen
GetSelectedPen
GetPenCount
GetPenPlotSize
SetPenPlotSize
|