![]() |
RemoveIndexedCollectionItem |
||||
Header: | Collections.h | Carbon status: | Supported | |
Removes an item from a collection given the items index.
OSErr RemoveIndexedCollectionItem ( Collection c, SInt32 index );
A reference to the collection object from which you want to remove the item. The behavior of this function is undefined if you do not provide a reference to a valid collection object.
The collection index of the item you want to remove.
A result code. If the c collection does not contain an item whose collection index matches the values in the index parameter, this function returns a collectionIndexRangeErr result code.
The RemoveIndexedCollectionItem function removes the item specified by the index parameter from the collection referenced by the c parameter. This function removes the specified item even if its lock attribute is set.
To remove a collection item using the items tag and ID (rather than the items index), use the RemoveCollectionItem function.
To replace an item in a collection, use the function ReplaceIndexedCollectionItem.
Supported in Carbon. Available in Carbon 1.0.2 and later when running Mac OS 8.1 or later.
© 2000 Apple Computer, Inc. (Last Updated 6/30/2000)