Important: The information in this document is obsolete and should not be used for new development.
PBGetEOF
You can use thePBGetEOFfunction to determine the current logical end-of-file of an open file.
FUNCTION PBGetEOF (paramBlock: ParmBlkPtr; async: Boolean): OSErr;
paramBlock- A pointer to a basic File Manager parameter block.
async- A Boolean value that specifies asynchronous (
TRUE) or synchronous (FALSE) execution.
--> ioCompletionProcPtrA pointer to a completion routine. <-- ioResultOSErrThe result code of the function. --> ioRefNumIntegerA file reference number. <-- ioMiscPtrThe logical end-of-file. DESCRIPTION
ThePBGetEOFfunction returns, in theioMiscfield, the logical end-of-file of the specified file. BecauseioMiscis of typePtr, you'll need to coerce the value to typeLongIntto interpret the value correctly.ASSEMBLY-LANGUAGE INFORMATION
The trap macro forPBGetEOFis_GetEOF.RESULT CODES
noErr 0 No error ioErr -36 I/O error fnOpnErr -38 File not open rfNumErr -51 Bad reference number afpAccessDenied -5000 User does not have the correct access to the file