DevExpress.XtraGrid.Columns.GridColumn[] col = ApptBL.GetInstance().GetDepartment().Select(x => new DevExpress.XtraGrid.Columns.GridColumn { VisibleIndex = i++, Caption = x.Name, FieldName = "Col" + x.Code }).ToArray();//Fixed= DevExpress.XtraGrid.Columns.FixedStyle.Left,
gridView2.Columns.AddRange(col);
dt.Columns.Add(new DataColumn("Date"));
dt.Columns.AddRange(col.Select(x => new DataColumn(x.FieldName)).ToArray());
gridView2.Columns.AddRange(col);
dt.Columns.Add(new DataColumn("Date"));
dt.Columns.AddRange(col.Select(x => new DataColumn(x.FieldName)).ToArray());