Help Center

AfxUnixDateStrfunction

Retuns the current Unix date based on the specified mask, e.g. "dd-MM-yyyy".

DateTimefunctionAfxTime.incdoc-orphan
No implementation located. This member is documented, but the source scan found no matching declaration. It is likely declared in a header this scan does not resolve, or provided by a macro.

Syntax

FUNCTION AfxUnixDateStr (BYVAL unixTime AS DWORD, BYREF wszMask AS WSTRING, BYVAL lcid AS LCID = LOCALE_USER_DEFAULT) AS DWSTRING

Parameters

NameDescription
unixTimeThe Unix time value.
wszMaskA picture string that is used to form the date.
The format types "d", and "y" must be lowercase and the letter "M" must be uppercase.
For example, to get the date string "Wed, Aug 31 94", the application uses the picture string "ddd',' MMM dd yy".
lcidOptional. The language identifier used for the conversion. Default is LOCALE_USER_DEFAULT.

Return value

The Unix date in string format.

Description

Retuns an Unix date based on the specified mask, e.g. "dd-MM-yyyy".

The following table defines the format types used to represent days.

The following table defines the format types used to represent months.

The following table defines the format types used to represent years.

Example

PRINT AfxUnixDateStr(AfxWindowsInstallDate, "dd-MM-yyyy")

Reference