Click here to Skip to main content
16,006,760 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
I have DataTransfterObjects (DTO) in separate layer so I think no need of model in wpf application. I only have View and viewmodel in the application.

Everything works fine but issue is how to implement INotifyPropertyChanged and INotifyDataErrorInfo in DTO. How to use functionalities of these two interfaces? How to make validations?

What I have tried:

I have three class libraries of BLL, DAL and DTO and a wpf application have ViewModel and View only, I am using DTO as a model in the wpf application. Now If I implement IDataErrorInfo for validations then will it work or I have to do more?
Posted
Updated 19-Sep-16 1:57am
v3
Comments
[no name] 18-Sep-16 8:10am    
No it's not urgent at all. Why not try and inherit those interfaces? "Teach me programming in a forum posting" is not a question.
sacpundir 18-Sep-16 8:37am    
nice suggestion thanks

1 solution

Change notifications (e.g. for bindings in wpf) should be implemented in a viewmodel - let the model alone... This would be MVVM - I don't mean you can not have a model-classes implemening these Interfaces - but in MVVM this would be a clear responsibillity of the ViewModel
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900