public BlankItem(DataSourceWrapper wrapper, GridView view, int id) { ItemObject = new PartContainer(); ItemObject.ID = id; Wrapper = wrapper; Wrapper.CustomRows.Add(ItemObject); View = view; view.GridControl.PaintEx += GridControl_PaintEx; View.ShowingEditor += new CancelEventHandler(View_ShowingEditor); Text = "[Empty String]"; }
public SummaryItem(DataSourceWrapper wrapper, GridView view, int id) { ItemObject = new PartContainer(); ItemObject.ID = id; Wrapper = wrapper; calcSummary(Wrapper.NestedList as BindingList <PartContainer>); wrapper.NestedList.ListChanged += new ListChangedEventHandler(list_ListChanged); Wrapper.CustomRows.Add(ItemObject); View = view; View.ShowingEditor += new CancelEventHandler(View_ShowingEditor); }
private void Form1_Load(object sender, EventArgs e) { dsw = new DataSourceWrapper(DataList, CustomRows); new BlankItem(dsw, gridView1, -1, "Only Custom Rows are placed under this Row"); dsw.CustomRows.Add(new PartContainer(-2, 5, 5, 5)); new BlankItem(dsw, gridView1, int.MinValue + 1, "The Summary Row calculates only Nested Data Row Values"); new SummaryItem(dsw, gridView1, int.MinValue); for (int i = 0; i < 10; i++) { DataList.Add(new PartContainer(i, i, i * 2, i * 3)); } gridControl1.DataSource = dsw; }
public BlankItem(DataSourceWrapper wrapper, GridView view, int id, string text) : this(wrapper, view, id) { Text = text; }