Programming instructions

Intermec Fingerprint v7.61 Programmers Reference Manual Ed. 7158
Chapter 2 Program Instructions
LOF
Field of Application
Function returning the length in bytes of an OPEN sequential or
random le, or returning the status of the buffers in an OPEN
communication channel.
Syntax LOF(<nexp>)
(<nexp>) is the number assigned to the le or communication channel
when it was OPENed.
Remarks
LOF can also be used to check the receive or transmit buffer of the speci ed
communication channel:
If a channel is OPENed for INPUT, the remaining free space (bytes) in
the receive buffer is returned.
If a channel is OPENed for OUTPUT, the remaining number of characters
to be transmitted from the transmit buffer is returned.
Examples
The rst example illustrates how the length of the le "Pricelist" is
returned:
10 OPEN "PRICELIST" AS #5
20 A%=LOF(5)
30 PRINT A%
. . . .
. . . .
The second example shows how the number of free bytes in the receive buffer
of communication channel "uart2:" is calculated:
100 OPEN "uart2:" FOR INPUT AS #2
110 A%=LOF(2)
120 PRINT A%