TDateEdit.SetDateMask procedure
Applies an EditMask based on the DateOrder for the control.
Declaration
procedure SetDateMask; virtualDescription
SetDateMask is a method used to update the EditMask for the
control. It also updates the internal member where a
FormatDateTime-compatible format string is stored. The mask value is
determined by the DateOrder property, and uses the following TDateOrder and
edit mask values:
- doNone
- EditMask is set to an empty string (''). The date format string is also an empty string.
- doDMY, doMDY
- EditMask is set to '99/99/9999;1;_'. The date format string is set to 'mm/dd/yyyy' (for doMDY) or 'dd/mm/yyyy' (for doDMY).
- doYMD
- EditMask is set to '9999/99/99;1;_'. The date format string is set to 'yyyy/mm/dd'.
SetDateMask retrieves and re-applies the current value in Date after the EditMask has been changed. This forces the display value in Text to be updated.
SetDateMask is called when a new value is assigned to the DateOrder property.
See also
An experiment, built from development snapshots. Not the official Free Pascal or Lazarus documentation.
