Fix conversion functions to allow TDate, TTime and TDateTime types.