Accessing historical values - D2_ArchArr function
The function D2_ArchArr provides a more effective access to historical values of D2000 system.
The function D2_ArchArr provides a more effective access to historical values of D2000 system.
D2_ArchArr
(archObjName,bt, et, step, attribute, bDirectionByRow, refresh)
archObjName | TEXT |
|
bt | ABS. TIME type | Begin time of the archive block. |
et | ABS. TIME type | End time of the archive block. |
step | INT type | Time step [s] within the archive block. |
attribute | TEXT type | Required attribute of historical value. |
bDirectionByRow | BOOL type | Time order of cells in matrix. |
refresh | Optional parameter. |
The procedure above has created a matrix containing selected cells. Expression is the same in all the cells.
The function returns an array of required attributes of the archive values (the parameter attribute – see the function D2_GetValue) of defined historical value. The parameters bt and et defines a time order of cells of the matrix. It is important only for matrix containing at once several rows and several columns. If the value of the parameter is TRUE, the values (ascending order by time) are inserted into cells row by row. Otherwise the values are inserted into cells column by column.
The parameter refresh - see the function D2_GetValue.
Value time from the archive is defined by is defined
by the relative position of the cell containing the function call and the matrix in which the cell is placed.
the times of individual values in cells, according the matrix range and the parameter bDirectionByRow, will be as follows:
The return value of the function for all the values out of required interval is an error message: #Value, or the value of the cell named SUPP_NO_ARCH_DATA if exists (see the topic Predefined cells).
Pridať komentár