AllocContigYou can use the
AllocContigfunction to allocate additional contiguous blocks to an open file.
FUNCTION AllocContig (refNum: Integer; VAR count: LongInt): OSErr;
- The file reference number of an open file.
- On input, the number of additional bytes to allocate to the file; on output, the number of bytes allocated, rounded up to the nearest multiple of the allocation block size.
AllocContigfunction is identical to the
Allocatefunction except that if there isn't enough contiguous empty space on the volume to satisfy the allocation request,
AllocContigdoes nothing and returns
dskFulErras its function result. If you want to allocate whatever space is available, even when the entire request cannot be filled by the allocation of a contiguous piece, call
noErr 0 No error dskFulErr -34 Disk full ioErr -36 I/O error fnOpnErr -38 File not open wPrErr -44 Hardware volume lock fLckdErr -45 File is locked vLckdErr -46 Software volume lock rfNumErr -51 Bad reference number wrPermErr -61 Read/write permission doesn't allow writing