I'm trying to create a custom date range user control which contains two XamDateTimeEditor ('DateFrom' and 'DateTo'). Also it has 2 dependency properties named in the same way. XamDateTimeEditor controls' Value properties are binded to corresponding property. There is a small validation logic that doesn't allow DateTo to be less that DateFrom and DateFrom to be bigger that DateTo. This is done by using CoerceValueCallbacks defined for user control's properties. Validation works ok but XamDateTimeEditor still display value that is set by user, for example: DateFrom is set to 29/03/2010 and DateTo is set to 30/03/2010. Then I set DateTo editor value to 28/03/2010 - user control's property value is reseted to 29/03/2010 but XamDateTimeEditor control displays 28/03/2010. I assume that if it's binded to property it should be also reseted to 29/03/2010. Is it some kind of issue or I'm doing something wrong? I've attached sample project.
Thank you, Alex.
Hello,
This is an issue on our end. I will create a support case on your behalf so that you will be notified when this is resolved and the service release is out.
It looks like we are not reflecting the value change from coercing when the editor is in edit mode. I am going to double check that with the development team and update the forum thread.