Next to the DesktopDateTimePicker date, I would like to save the hours and minutes from the DataTimePicker to the database as well, but can’t figure out how this would work. Saving the date to and from the database table is no problem, so I assume I should somehow add the Hour/minutes property to it?
This is the code I use for saving to the database table:
var SelectedDate as string
SelectedDate = WinStoryCalendarEvents.DateTimePickerEvents.SelectedDate.SQLDate
App.db.ExecuteSQL("UPDATE events SET EventDate = ? WHERE ID = ?", SelectedDate, EventID_Selected)
This is the code in the listbox that reads the date back from the DataTimePicker:
DateTimePickerEvents.SelectedDate = rs.Column("eventdate").DateTimeValue
Where do I add the code for the hours and minutes?
I love btw how this look in the App: