AccControl
Controls accumulators, for example, motor run hours. You can reset the values of Run Time, Totalizer Inc, and No. of Starts (defined in the Accumulator database), re-read these values from the I/O device, or flush pending writes of these values to the I/O device.
Syntax
AccControl(sName, nMode [, ClusterName] )
sName:
The name of the accumulator or a mask for the names of accumulators. You can use the following wildcards:
This argument can be prefixed by the name of the cluster for example ClusterName.AccumulatorName.
nMode:
The mode of the control:
1 - Reset Run Time and Totalizer value
2 - Reset No. of Starts
3 - Reset Run Time, Totalizer value, and No. of Starts
4 - Flush pending writes to the I/O device
5 - Re-read Run Time, Totalizer value, and No. of Starts from the I/O device
ClusterName:
Name of the cluster in which the accumulator resides. This is optional if you have one cluster or are resolving the reports server via the current cluster context. The argument is enclosed in quotation marks "".
Return Value
0 (zero) if successful, otherwise an error is returned.
Example
! Reset all accumulator variables for accumulator "MCC123".
AccControl("MCC123", 3, "ClusterXYZ");
See Also