Beispiel #1
0
        private void btnAdd_Click(object sender, EventArgs e)
        {
            int      id  = TextUtils.ToInt(treeData.FocusedNode.GetValue(colIDTree));
            frmCCost frm = new frmCCost();

            frm.CatID           = id;
            frm.LoadDataChange += main_LoadDataChange;
            frm.Show();
        }
Beispiel #2
0
        private void btnEdit_Click(object sender, EventArgs e)
        {
            int id = TextUtils.ToInt(grvData.GetFocusedRowCellValue(colID));

            if (id == 0)
            {
                return;
            }
            C_CostModel model = (C_CostModel)C_CostBO.Instance.FindByPK(id);
            int         catId = TextUtils.ToInt(grvData.GetFocusedRowCellValue(colGroup));

            _rownIndex = grvData.FocusedRowHandle;

            frmCCost frm = new frmCCost();

            frm.CatID           = catId;
            frm.CurrentCost     = model;
            frm.LoadDataChange += main_LoadDataChange;
            frm.Show();
        }