问题描述
- asp.net求助????????,求解答
-
public virtual object DataSource
{
[TargetedPatchingOptOut("Performance critical to inline this type of method across NGen image boundaries")]
get
{
return this.dataSource;
}
set
{
if (((value != null) && !(value is IListSource)) && !(value is IEnumerable))
{
throw new ArgumentException(SR.GetString("Invalid_DataSource_Type", new object[] { this.ID }));
}
this.dataSource = value;
this.OnDataPropertyChanged();
}
}
上面这段代码什么意思?谁能给我解释一下?
解决方案
就是定义了一个 DataSource的属性,并且在它更改的时候触发OnDataPropertyChanged事件。
时间: 2024-08-12 21:24:42