Carbon


TXNGetChangeCount

Header: MacTextEditor.h Carbon status: Supported

Retrieves the number of times a document has been changed.

ItemCount TXNGetChangeCount (
    TXNObject iTXNObject
);
Parameter descriptions
iTXNObject

A variable of type TXNObject. Pass the text object whose changes you want to count.

function result

A variable of type ItemCount that specifies the total number of changes since the document was last saved. If the document is new, ItemCount specifies the number of changes since it was created.

DISCUSSION

The change count increments for every executed command such as Cut— or Copy—, and for every key-down event. The count is cleared each time the text object is saved. You can use this function to determine if the Save item in the File menu should be active.

AVAILABILITY

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 7/17/2000)