HTBasic Help
×
Menu
Index

ON EOT

Defines an event branch for end-of-transfer conditions.
 
 ON EOT @io-path [,priority] action
 
Usage:
ON EOT @Dev GOTO 1200
ON EOT @Code,2 CALL Done
 
Example:           ON EOT.BAS
 
Description:
When a TRANSFER finishes, an end-of-transfer, EOT, event occurs which may be caught by the ON EOT statement. The ON EOT statement must be executed before the TRANSFER ends.
 
The I/O path must be the I/O path used in the TRANSFER to specify the device. Using the I/O path assigned to the buffer will cause an error.
If another ON EOT is executed in a different program context, the original ON EOT definition is restored when control returns to the calling context.
 
ON EOT is canceled by OFF EOT and is disabled by DISABLE. A SUBEXIT, SUBEND, or RETURN from the defining subprogram also cancels it. If a context exit is delayed until a TRANSFER terminates, any EOT events generated during the delay are discarded. Use WAIT FOR EOT to force the event to be serviced before the subprogram exits.
 
More information about ON EOT can be found under the "Common Information" heading of the ON CYCLE manual entry.
 
See Also: