SortColFmt$ |
Grid Column Sorting Format |
Grid column sorting format
This property is used to control the sorting of grid columns when a sort by date is required. Normally, when the grid sorts columns, it does so by either a numeric value comparison or a string compare. If the column contains a date, you need to tell the system the format of the date being provided so it can determine which value is the year, month or day respectively.
The SortColFmt$ property is used to control the sorting of date columns. This property can be set from one to three characters long where each character can be a '#', 'S', 'Y', 'M' or 'D', as follows:
Example: If the date is of the form day, month, then year, the 'SortColFmt$ property should be set to "DMY".
If this field is not set, the column will be pre-scanned to determine if all values are numeric. If all the column data is numeric, then a numeric sort will be performed; otherwise, a string sort will be used.
The 'SortColFmt$ property works in conjunction with the 'Column or 'Colno property to identify the column to which the sort format will be applied.
(The SortColFmt$ property was added in PxPlus v7.10.)
(The ability to specify a format or "#" or "S" was added in PxPlus v11.)
The default value is "" (no sorting definition).
GRID