예제 #1
0
        private void btnAdd_Click(object sender, EventArgs e)
        {
            try
            {
                frmCustomerTypeAdd frm = new frmCustomerTypeAdd(0);
                LBShowForm.ShowDialog(frm);

                LoadDataSource();
            }
            catch (Exception ex)
            {
                LB.WinFunction.LBCommonHelper.DealWithErrorMessage(ex);
            }
        }
예제 #2
0
        private void ShowEdit()
        {
            if (this.grdMain.SelectedCells.Count == 0)
            {
                LB.WinFunction.LBCommonHelper.ShowCommonMessage("请选择需要编辑的行!");
                return;
            }

            long lCustomerTypeID   = LBConverter.ToInt64(this.grdMain.Rows[this.grdMain.SelectedCells[0].RowIndex].Cells["CustomerTypeID"].Value);
            frmCustomerTypeAdd frm = new frmCustomerTypeAdd(lCustomerTypeID);

            LBShowForm.ShowDialog(frm);

            LoadDataSource();
        }