private void EmplCDC_CollectionChanged(object sender, System.Collections.Specialized.NotifyCollectionChangedEventArgs e) { Percentage = EmplCDCDetail.Where(em => em.cdc != null).Sum(em => em.cdcPercentage); foreach (EmplCDCDetail d in EmplCDCDetail) { d.PropertyChanged -= D_PropertyChanged; d.PropertyChanged += D_PropertyChanged; } }
private void D_PropertyChanged(object sender, PropertyChangedEventArgs e) { Percentage = EmplCDCDetail.Where(em => em.cdc != null).Sum(em => em.cdcPercentage); }