views:

30

answers:

1

I'm using the Silverlight DatePicker and TimePicker from the toolkit together to allow a user to select a date and time. They are bound to the same DateTime value on a business object behind the scences. This mostly works okay, except when the date component is changed the time component is wiped. This is kinda logical but probably not the behaviour the user wanted.

There's a couple of ways I could hack my way round this:

  • Store the date and time components in different values (not that hacky but a little anonying as I'm going to store the resulting value as one field in a db)
  • Try and fix up the time component when the SelectedDateChanged event fires (which does seem a very hacky solution)

I'd like to be able to tell the DatePicker control: just leave the time component when you change date. Am I hoping for too much?