Romfile.Pointer Property

Top  Previous  Next

 

Function:

Sets/returns current (pointer) position in the resource (ROM) file.

Type:

Word

Value Range:

See explanation below

See Also:

Romfile Object

 


Details

When the file is (re)opened with the romfile.open method, the pointer is reset to the first character of the file (position 1), except when the file is not found or contains no data, in which case the pointer will permanently be equal to 0. Pointer position cannot exceed file size (see the romfile.size property). When you read from the file using the romfile.getdata method the pointer is automatically moved forward by the number of characters that have been read out.

 

note_warning-wt

The romfile object can only access first 65534 bytes of each file. This is because the romfile.pointer is a variable of word type.