This function will return the current buffer (cursor) position in the specified buffer. This position is used as starting point for most buffer operations, which in any way read, write, copy or search data. You should immediately use the retrieved position, as it will change with almost all buffer operations.
SYNTAX:
curPos& = GetBufPos& (buf$())
INPUTS:
buf$() (STRING array)
- This is the array of any existing and initialized buffer, from which you wanna retrieve the current position.
RESULT:
curPos& (LONG)
- The retrieved position, this is always in the range 1 to GetBufLen() + 1.
- The latter one is the "End Of Buffer" position, ie. one byte past the current buffer contents, where no more valid data is readable, but in which new data is appended when writing to the buffer end.