
MVVM模式中的基本内容绑定
1、数据绑定:
依赖属性:数据Model必须继承DependencyObject
属性名称+Changed事件:固定写法
INotifyPropertyChanged接口:形成一种契约
2、基于Model的数据验证
Exception
Required、StringLength、Range、RegularExpression、Custom
Model层
public class InfoModel : NotifyPropertyBase
{
//public event EventHandler NameChanged;