TApxComPort.InBuffFree

TApxComPort

property InBuffFree : Word

Returns the number of bytes free in the dispatcher buffer.

This routine returns the number of bytes of free space in the Async Professional CLX
dispatcher buffer. It does not tell you the free space in the communications
driver input buffer.

Because the dispatcher automatically drains the buffer using timer and notification messages, its status is rarely relevant to the program.

The following example checks to see that there's significant free space in the dispatcher buffer before performing a time-consuming operation that doesn't drain the buffer:

if ApxComPort.InBuffFree > 128 then
  ...perform a time-consuming operation

See also: InBuffUsed