Aug 30, 2002 #1 Nordlund Programmer Jul 17, 2001 458 SE Hi all... If I have 2 TDateTimePicker components, One showing time, another showing date. How the heck do I adding the time and the date? Have fun, keep on playing......
Hi all... If I have 2 TDateTimePicker components, One showing time, another showing date. How the heck do I adding the time and the date? Have fun, keep on playing......
Aug 30, 2002 Thread starter #2 Nordlund Programmer Jul 17, 2001 458 SE Ok. I've got my own solution, but is there another, better way to solve it? var T1, T2: TTimeStamp; theDate: TDateTime; begin T1 := DateTimeToTimeStamp(DatePicker.Date); T2 := DateTimeToTimeStamp(TimePicker.Date); T1.Time := T2.Time; theDate := TimeStampToDateTime(T1); end; Upvote 0 Downvote
Ok. I've got my own solution, but is there another, better way to solve it? var T1, T2: TTimeStamp; theDate: TDateTime; begin T1 := DateTimeToTimeStamp(DatePicker.Date); T2 := DateTimeToTimeStamp(TimePicker.Date); T1.Time := T2.Time; theDate := TimeStampToDateTime(T1); end;
Aug 30, 2002 Thread starter #3 Nordlund Programmer Jul 17, 2001 458 SE And onther 3rd better way is to erase the Date portion in the TimePicker and the Time portion in the Date Picker... Thanks Mats... Upvote 0 Downvote
And onther 3rd better way is to erase the Date portion in the TimePicker and the Time portion in the Date Picker... Thanks Mats...
Aug 30, 2002 #4 McMerfy Programmer Apr 18, 2002 186 RU DatePicker.Date + TimePicker.Time ? --- markus Upvote 0 Downvote
Sep 2, 2002 Thread starter #5 Nordlund Programmer Jul 17, 2001 458 SE Yep. that did the trick, but before I got it to work, I had to remove the time on the date component and vice versa Upvote 0 Downvote
Yep. that did the trick, but before I got it to work, I had to remove the time on the date component and vice versa