Date time field - CustomDateFormat Property

Format for date to be displayed

Member of Date time field (PRIM_MD.DateTime)

Data Type - String

Details

The CustomDateFormat property is used to format the date using the supplied formatting strings.
 
Each portion of the custom definition is evaluated independently and then concatenated to produce the output.

Date Format

Enum Value Description
Y Short year with suppressed leading zero e.g. 4
YY Short year e.g. 04
YYY Long year e.g. 2004
M Short month with suppressed leading zero e.g. 4
MM Short month e.g. 04
MMM Long month e.g. April
D Short date with suppressed leading zero e.g. 4
DD Short date e.g. 04
DDD Abbreviated date name e.g. Wed
DDDD Long date name e.g. Wednesday

Example

A format of "DDDD, D MMM YYYY" would produce the output "Wednesday, 7 Nov 2012"

See also

All Component Classes

Technical Reference

LANSA Version 15, April 2020