From Liberty BASIC Family
Jump to navigation Jump to search
Supported in Just BASIC Supported in Liberty BASIC Not supported in Liberty BASIC 5 Not supported in Run BASIC


Retrieves the current position of the file pointer for a file opened in Binary access mode. The current position of the pointer is used when writing to or reading from the file.
See also SEEK.


  1. loc(#handle)


' Usage
open "myfile.bin" for binary as #1

'get the current file-pointer position
fpos = loc(#1)

'display the current file-pointer position
PRINT "File Pointer is currently located at Position "; fpos

'close the file

Useful Procedures

' Place a useful function or sub using this keyword here