private void OnLayoutViewCustomFieldValueStyle(object sender, LayoutViewFieldValueStyleEventArgs e) { LayoutView view = (LayoutView)sender; int sourceIndex = view.GetDataSourceRowIndex(e.RowHandle); string key = string.Format("{0}|{1}", sourceIndex, e.Column.FieldName); e.Appearance.Font = cache.ContainsKey(key) ? modified : regular; }
public override IList GetSelectedObjects() { if (layoutView == null || DataSource == null) { return new object[0] { } } ; int[] selection = layoutView.GetSelectedRows(); List <object> result = new List <object>(); for (int i = 0; i < selection.Length; i++) { if (layoutView.IsDataRow(selection[i])) { result.Add(((IList)DataSource)[layoutView.GetDataSourceRowIndex(selection[i])]); } } return(result); }