Promotic
WikipediaLinkedInYoutubeTwitterFacebook

Refresh - method of object PmOpcClientData

Description:
It enables reading all values of the data group (defined on the Data page) from the OPC server.
Syntax:
Refresh(Attr As Long) As Boolean
Calling:
oClientData.Refresh Attr
Parameters:
Attr(Long) the way of the transfer: (see OPC Basic terms)
0 - data from the CACHE
1 - data from the DEVICE
Return Values:
true - on success
false - on error
Note:
The method always reads all data. If it is requested to read only the specific data (into the Data page), the Read method can be used. The Refresh method is the asynchronous operation (see OPC Basic terms).

The Refresh method needn't be called if the configurator Update from server at server change is set on the Parameters page because the data are then "read" automatically.

Example:
If oClientData.Refresh(0) Then
  ...
End If
© MICROSYS, spol. s r. o.Tavičská 845/21 703 00 Ostrava-Vítkovice