阅读背景:

如何强制收集项目中的单一性

来源:互联网 

I have scenario in project where we need to fetch all active book records from database and hold in observablecollection. This observale Collection is bound to grid control in WPF application where user can add remove books. We need to persist all added, removed and modified records in collection till user hit the save to database. Our contraint is book name and IBN number of book must be unique. If user add new book with duplicate book name that already present in collection then we need to invalidate that object, so that it will not allow user to save in database till all collection object are not valid. I know it can be achieved with different ways, I want to know about best practices to do this. Any solution with IDataErrorInfo or Enterprise Validation Library is appreciated.I have scenario in project where we need to fet




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: