Quantcast
Channel: WPF Reflections » Databinding
Viewing all articles
Browse latest Browse all 10

Data validation in WPF, my approach

$
0
0

Whether to use IDataErrorInfo or ValidationRule – that is the question, as I posed in a previous post.

So , you may be wondering what do I do in my WPF projects?
Or you may not :-)

Well, I tend to use both!
I use IDataErrorInfo to provide validation in the business object itself, then derive extra classes from ValidationRule when I want validation across different business objects.

I have tried making the Validation classes always separate from the pure data business classes, but I found it to be counter productive and also counter intuitive.


Viewing all articles
Browse latest Browse all 10

Trending Articles



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