LOC function (LotusScript® Language)

Returns the current position of the file pointer in a file.

Syntax

LOC ( fileNumber )

Elements

fileNumber

The number assigned to the file when you opened it.

Return value

The following table presents the LOC return values for random, sequential, and binary files.

File type

Return value

Random

The number of the last record read from or written to the file. This is the file pointer position, minus 1.

Sequential

The byte position in the file, divided by 128 and truncated to an integer.

Binary

The position of the last byte read from or written to the file. This is the file pointer position, minus 1.

Example