Ron Weston
Ron Weston

Reputation: 290

silverlight datepicker show original 'incorrect date' text

I'm using the Silverlight Toolkit DatePicker control.

If an user enters an invalid format date for example foo/bar/2001 then the DatePicker automatically 'ignores' the date and sets it back to the last date.

This behaviour is fine, except I'd like to actually show the date in error to the user (not corrected) and display some validation message etc so the user knows what the issue is

Does anyone have a snip or sample I can use that works in this way?

Any help greatly appreciated.

Upvotes: 2

Views: 1029

Answers (1)

DaveB
DaveB

Reputation: 9530

You could handle the DateValidationError event. Calendar control in Silverlight using C# has a bit of sample code showing how the event handler could be wired up.

Upvotes: 2

Related Questions