Hello Derek
Can this help you .
Example code : Showing all of the date field formatting data types
var
myDate : TDateTime;
formattedDateTime : string;
begin
// Set up our TDateTime variable with a full date and time :
// 5th of June 2000 at 01:02:03.004 (.004 milli-seconds)
myDate := EncodeDateTime(2000, 6, 5, 1, 2, 3, 4);
// Date only - numeric values with no leading zeroes (except year)
DateTimeToString(formattedDateTime, 'd/m/y', myDate);
ShowMessage(' d/m/y = '+formattedDateTime);
// Date only - numeric values with leading zeroes
DateTimeToString(formattedDateTime, 'dd/mm/yy', myDate);
ShowMessage(' dd/mm/yy = '+formattedDateTime);
// Use short names for the day, month, and add freeform text ('of')
DateTimeToString(formattedDateTime, 'ddd d of mmm yyyy', myDate);
ShowMessage(' ddd d of mmm yyyy = '+formattedDateTime);
// Use long names for the day and month
DateTimeToString(formattedDateTime, 'dddd d of mmmm yyyy', myDate);
ShowMessage('dddd d of mmmm yyyy = '+formattedDateTime);
// Use the ShortDateFormat settings only
DateTimeToString(formattedDateTime, 'ddddd', myDate);
ShowMessage(' ddddd = '+formattedDateTime);
// Use the LongDateFormat settings only
DateTimeToString(formattedDateTime, 'dddddd', myDate);
ShowMessage(' dddddd = '+formattedDateTime);
// Use the ShortDateFormat + LongTimeFormat settings
DateTimeToString(formattedDateTime, 'c', myDate);
ShowMessage(' c = '+formattedDateTime);
end;
JB