Quantcast
Channel: wpftoolkit Discussions Rss Feed
Viewing all articles
Browse latest Browse all 2157

New Post: IntegerUpDown not triggering binding property

$
0
0
Hi,

You can listen to event UpDownBase.InputValidationError. This event will be raised when the focus goes away from the IntegerUpDown (or "Enter" key is pressed) while non-numeric characters are typed in the IntegerUpDown.

This kind of error is flagged by the Int32.TryParse method, which fails when non-numeric characters are used. As you can see during debug : an exception is thrown.
UpDownBase.Value will always contains numeric values(removing non-numeric values), while InputBase.Text will contains the typed text (with the non-numeric characters).

In the callback of event UpDownBase.InputValidationError, you have access to InputBase.Text property to know what was typed.

Viewing all articles
Browse latest Browse all 2157

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>