예제 #1
0
        private void BtnAdd_Click(object sender, EventArgs e)
        {
            FmProjectCostInfo fmGenAdd = new FmProjectCostInfo();

            fmGenAdd.SelectValue += (object obj) =>
            {
                mDataGrid1.AddItem <Model.Info_project_Cost_Item>((Model.Info_project_Cost_Item)obj);
            };
            fmGenAdd.ShowDialog();
        }
예제 #2
0
        private void BtnEdit_Click(object sender, EventArgs e)
        {
            if (mDataGrid1.CurrentRow == null)
            {
                return;
            }

            Model.Info_project_Cost_Item info = mDataGrid1.GetCurrentEntity() as Model.Info_project_Cost_Item;

            FmProjectCostInfo fmGenUpdate = new FmProjectCostInfo(info);

            fmGenUpdate.SelectValue += (object obj) =>
            {
                mDataGrid1.EditCurrentItem <Model.Info_project_Cost_Item>((Model.Info_project_Cost_Item)obj);
            };
            fmGenUpdate.ShowDialog();
        }