You could use one of
DateTime
structure's constructors:
DateTime Constructor (System) | Microsoft Docs[
^]
Or, since the datetime picker most probably returns you a
TimeSpan
, you could just add it to specified date at 00:00:00. You can add a
TimeSpan
value to a
DateTime
value to get a new
DateTime
.
DateTime baseDate = DateTime.Today;
DateTime preIn = baseDate + preBreakTimeClockIn;
DateTime preOut = baseDate + preBreakTimeClockOut;
DateTime postIn = baseDate + postBreakTimeClockIn;
DateTime postOut = baseDate + postBreakTimeClockOut;