Sub Get_Date
dd.DateTicks = IncidentDate
If dd.Show("Please Select Incident Date", "Incident Date", "Ok", "Cancel", "", Null) = DialogResponse.POSITIVE Then
IncidentDate = DateTime.DateParse(NumberFormat2(dd.Year, 4, 0, 0, False) & "-" & NumberFormat(dd.Month, 2, 0) & "-" & NumberFormat(dd.DayOfMonth, 2, 0) & " " & NumberFormat(DateTime.GetHour(IncidentDate), 2, 0) & ":" & NumberFormat(DateTime.GetMinute(IncidentDate), 2, 0))
VM.SetText("IncidentDate", DateTime.Date(IncidentDate))
End If
End Sub
Sub Get_Time
td.TimeTicks = IncidentDate
td.Is24Hours = True
If td.Show("Please Select Incident Time", "Incident Time", "Ok", "Cancel", "", Null) = DialogResponse.POSITIVE Then
IncidentDate = DateTime.DateParse(NumberFormat2(DateTime.GetYear(IncidentDate), 4, 0, 0, False) & "-" & NumberFormat(DateTime.GetMonth(IncidentDate), 2, 0) & "-" & NumberFormat(DateTime.GetDayOfMonth(IncidentDate), 2, 0) & " " & NumberFormat(td.Hour, 2, 0) & ":" & NumberFormat(td.Minute, 2, 0))
VM.SetText("IncidentDate", DateTime.Date(IncidentDate))
End If
End Sub