public void setGridViewDataSource(DataTable _dt) { lock (m_lock_datasource) { ObjOrder.makeTableSchema(ref _dt); // set table columns with ObjOrder class gridControl.DataSource = _dt; } }
public DataTable getGridViewDataSource() { lock (m_lock_datasource) { DataTable dt = (DataTable)gridControl.DataSource; if (null == dt) { dt = new DataTable(); if (null != dt) { ObjOrder.makeTableSchema(ref dt); // set table columns with ObjOrder class gridControl.DataSource = dt; } else { Debug.Assert(false); } } return(dt); } }