onEndOfTransfer - event of object PmCommMsg

The event fires after the transfer of the whole message with any result. It can be used, for example, to find out if the message has been successfully transferred.
pMe(Object) Reference to the PROMOTIC object where the event rises.
pEvent(Object) A referrence to object describing detailed information about the specific event.
pEvent.Error - (Long) success rate of the message transfer.
0 - the transfer passed successfully
4 - transfer proceeded without errors but less data were received than expected
5 - transfer proceeded without errors but more data were received than expected
21 - error in the message setting (wrong configured page Data-sent, Data-received or Parameters)
24 - timeout from the input (sufficient number of characters wasn't accepted)
33 - software error
62 - negative acknowledement
65 - wrong transmitted data (e.g. the wrong configuration of the communication card)
66 - wrong received data (e.g. the check sum error)
67 - not possible to create the connection with the server (Ethernet) or the port is not ready for the communication (serial link).
Fireing of this event can even be emulated in the INFO system when the local menu is opened on the (by the right mouse button) while viewing this object. See permission PmRoot > Permissions > InfoEdit.

The error state can be detected even after this event using the LastErr and LastTextErr properties. Cumulative error count can be detected by the PmCommMsg.GetCount or PmComm.GetCount method (it is usefull when detecting communication problems).

the following script in this event reads the received value from the communication and then saves it into the variable in the PmData object.
Dim val
pMe.Pm("/Boiler1/Data/#vars/Temperature").Value = 100 + 10 * val
PROMOTIC 8.3.19 SCADA system documentation - MICROSYS, spol. s r.o.

Send page remarkContact responsible person
© MICROSYS, spol. s r. o.Tavičská 845/21 703 00 Ostrava-Vítkovice