title: Passing state of WPF ValidationRule to View Model in MVVM
body: <p>I am stuck in a seemingly common requirement. I have a WPF Prism (for MVVM) application. My model implements the <strong>IDataErrorInfo</strong> for validation. The <strong>IDataErrorInfo</strong> works great for non-numeric properties. However, for numeric properties, if the user enters invalid characters (which are not numeric), then the data doesn't even reach the model because wpf cannot convert it to numeric type. </p>
  
  <p>So, I had to use WPF ValidationRule to provide user some meaningful message for invalid numeric entries. All the buttons in the view are bound to DelegateCommand of prism (in view model) and the enabling/disabling of buttons is done in View Model itself. </p>
  
  <p>Now if a wpf ValidationRule fail for some TextBox, how do I pass this information to View Model so that it can appropriately disable buttons in the view ?</p>