Carbon


GetDateTime

Header: DateTimeUtils.h Carbon status: Supported

Obtains the current date-time information, expressed as the number of seconds elapsed since midnight, January 1, 1904.

void GetDateTime (
    UInt32 *secs
);
Parameter descriptions
secs

On return, the number of seconds elapsed since midnight, January 1, 1904.

DISCUSSION

The low-memory copy of the date and time information is also accessible through the global variable Time.

If an application disables interrupts for longer than a second, the date-time information returned by the GetDateTime function might not be exact. The GetDateTime function is intended to provide fairly accurate time information, but not scientifically precise data.

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 6/30/2000)