111,131
社区成员
发帖
与我相关
我的任务
分享
cogRecordsDisplay1.DataBindings.Add("Subject", UIProperty.Instance, "RecordLift");
public class UIProperty : INotifyPropertyChanged
{
private static UIProperty set = new UIProperty();
public static UIProperty Instance
{
get
{
return UIProperty.set;
}
set
{
UIProperty.set = value;
}
}
ICogRecord _recordLift=null;
public ICogRecord RecordLift
{
get
{
return _recordLift;
}
set
{
_recordLift = value;
FireStrChanged();
}
}
//必须实现INotifyPropertyChanged接口的此事件
public event PropertyChangedEventHandler PropertyChanged;
public void FireStrChanged(string propertyName="")
{
PropertyChanged.Invoke(this, new PropertyChangedEventArgs(propertyName));
}
}
