Help Center

CPowerTime.TimeStringmethod

Returns the time as a string based on the specified mask, e.g. "dd-MM-yyyy".

DateTimemethoddocumented

Syntax

FUNCTION TimeString (BYREF wszMask AS WSTRING, BYVAL lcid AS LCID = LOCALE_USER_DEFAULT) AS DWSTRING

Parameters

NameDescription
ftA FILETIME structure.
wszMaskA picture string that is used to form the time.
lcidOptional. The language identifier used for the conversion. Default is LOCALE_USER_DEFAULT.

Return value

The formatted time.

Description

Retuns the time as a string based on the specified mask, e.g. "hh':'mm':'ss".

The application can use the following elements to construct a format picture string. If spaces are used to separate the elements in the format string, these spaces appear in the same location in the output string. The letters must be in uppercase or lowercase as shown, for example, "ss", not "SS". Characters in the format string that are enclosed in single quotation marks appear in the same location and unchanged in the output string.

Reference

  • Defined in AfxNova/CPowerTime.inc:942
  • Documented in DateTime/CPowerTime Class.md
  • Topic: CPowerTime Class