WritePartialResource
long offset ; byte offset value
Ptr buffer ; source buffer long count ; number of bytes in buffer
which allows you to work with small portions of large resources. The resource
is specified by the parameter theResource from the offset parameter, which is
in bytes, through the number of bytes given by the value of the count
you indicate with the buffer parameter. You are responsible for the memory
management of this buffer. Call the ResError function to check for errors. If the disk or the file is locked, the ResError function returns the appropriate file system error. If you try to write past the end of a resource,
the writingPastEnd result code if the attempt is successful. If it cannot enlarge
the resource, ResError returns the appropriate file system error. If you pass an invalid value in the offset parameter, ResError returns the inputOutOfBounds result code.
is successful, ResError returns resourceInMemory and does not update the copy in memory. You should be aware that in this situation, the copy in
memory is different from the resource on disk. If the attempt to write the
resource to disk is not successful, ResError returns the appropriate error. When using partial resource routines, you should call the SetResLoad procedure specifying FALSE for its load parameter before you call the to restore the normal state of the SetResLoad procedure after you call the dskFulErr (-34) Disk full
resourceInMemory (-188) Resource already in memory
writingPastEnd (-189) Writing past end of file
inputOutOfBounds (-190) Offset or count out of bounds