using System; using System.Data; using DevExpress.XtraEditors; using UAS_PLCDataReader.Entity; namespace UAS_PLCDataReader.CustomerControl.Button { public partial class ButtonAddRow : SimpleButton { private AutoDataGridControl.AutoDataGridControl grid; public AutoDataGridControl.AutoDataGridControl Grid { get { return grid; } set { grid = value; } } public ButtonAddRow() { InitializeComponent(); } private void ButtonSaveGrid_Click(object sender, EventArgs e) { } private void ButtonAddRow_Click(object sender, EventArgs e) { DataTable dt = (DataTable)grid.DataSource; if (dt != null) dt.Rows.Add(); } } }