GetReady - method of the PmaCommMsg object
Description:
Detects whether the PmaCommMsg object is ready to transfer the message.
Syntax:
Boolean GetReady()
Return values:
true - Object is ready to transfer the message (the
Run method can be called)
false - Object is not ready to transfer the message (the message from the previous calling the
Run method is still transferring)
Note:
The
PmaCommMsg object gets in the
transfer data state by the
Run method. During the transfer the
Run method cannot be re-called over the object and the
GetReady method then returns the value
false. After the transfer (i.e. after the
onEndOfTransfer event is triggered) the
Run method can be called again and the
GetReady method returns the value
true.
This method is functional only if the message is of the
Master type (i.e. if the "
Message type" configurator is set to "
Master").
Example:
JavaScriptVBScriptSelect and copy to clipboard
var oCommMsg = pMe.Pm("/Comm/mr");
if (oCommMsg.GetReady())
{
oCommMsg.Run();
}
else
{
Pm.Debug("PmaCommMsg is not ready (the previous message is being transmitted)");
}
Dim oCommMsg
Set oCommMsg = pMe.Pm("/Comm/mr")
If oCommMsg.GetReady() Then
oCommMsg.Run
Else
Pm.Debug "PmaCommMsg is not ready (the previous message is being transmitted)"
End If