![]() |
LongTimeString |
||||
Header: | DateTimeUtils.h | Carbon status: | Supported | |
Converts a time that is specified as a LongDateTime value into a Pascal string, making use of the time formatting information in the specified resource.
void LongTimeString ( LongDateTime *dateTime, Boolean wantSeconds, Str255 result, Handle intlHandle );
A pointer to a 64-bit, signed representation of the number of seconds since Jan. 1, 1904. This allows coverage of a much longer span of time (plus or minus approximately 30,000 years) than the standard, 32-bit representation.
A flag that indicates whether the seconds are to be included in the resulting string. LongTimeString produces a string that includes the seconds if you set this parameter to TRUE.
On output, contains the string representation of the time.
A handle to a numeric-format ('itl0') resource that specifies time formatting information for use in the conversion. If you specify NULL as the value of the resource handle parameter, LongTimeString uses information from the current script.
The numeric-format resource specifies whether or not to use leading zeros for the time values, whether to use a 12- or 24-hour time cycle, and how to specify morning or evening if a 12-hour time cycle is used.
You can use the LongSecondsToDate and LongDateToSeconds functions to convert between the LongDateRec (as produced by the StringToTime function) and LongDateTime data types.
LongTimeString may move memory; your application should not call this function at interrupt time.
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)