Legacy Documentclose button

Important: The information in this document is obsolete and should not be used for new development.

Previous Book Contents Book Index Next

Inside Macintosh: More Macintosh Toolbox /
Chapter 2 - Scrap Manager / Scrap Manager Reference
Routines / Transferring Data Between the Scrap in Memory and the Scrap on Disk


UnloadScrap

You can use the UnloadScrap function to write the scrap from memory to the scrap file.

FUNCTION UnloadScrap: LongInt;
DESCRIPTION
The UnloadScrap function writes the scrap in memory to the scrap file and releases the memory occupied by the scrap in your application's heap. The scrap file is located in the System Folder of the startup volume and has the filename as indicated by the scrapName field of the scrap information record (usually "Clipboard"). If the scrap is already on the disk, the UnloadScrap function does nothing.

UnloadScrap returns as its function result a long integer corresponding to a result code.

SPECIAL CONSIDERATIONS
The UnloadScrap function may move or purge memory blocks in the application heap. Your application should not call this function at interrupt time.

RESULT CODES
noErr0No error
dskFulErr-34Disk full
ioErr-36I/O error

Previous Book Contents Book Index Next

© Apple Computer, Inc.
6 JUL 1996