Пример #1
0
        public void newMember()
        {
            frmMember frm = new frmMember(-1, -1);

            frm.MdiParent = this;
            frm.Show();
        }
Пример #2
0
        private void dgExtraCards_CellClick(object sender, DataGridViewCellEventArgs e)
        {
            try
            {
                if (e.ColumnIndex == dgExtraCards.Columns["colDelete"].Index)
                {
                    if (MessageBox.Show("This will delete the Extra Card permanently when you click Save",
                                        "Delete Extra Card", MessageBoxButtons.OKCancel, MessageBoxIcon.Warning) == DialogResult.OK)
                    {
                        mbr.ExtraCards.Rows[e.RowIndex]["Deleted"] = true;
                    }
                }
                else if (e.ColumnIndex == dgExtraCards.Columns["colPromote"].Index)
                {
                    int       ID  = int.Parse(dgExtraCards["ID", e.RowIndex].Value.ToString());
                    frmMember frm = new frmMember(ID, mbr.ID);
                    frm.Show();
                }
                else if (e.ColumnIndex == dgExtraCards.Columns["colEdit"].Index)
                {
                    int       ID  = int.Parse(dgExtraCards["ID", e.RowIndex].Value.ToString());
                    frmMember frm = new frmMember(ID, -1);
                    frm.IsExtra = true;
                    frm.Show();
                }
            }
            catch (Exception ex)
            {
                ErrorLogger.Log("Error trying to modify an Extra Card", ex, true);
            }

            this.Refresh();
        }
Пример #3
0
        public void editMember(int memberId)
        {
            frmMember frm = new frmMember(memberId, -1);

            frm.MdiParent = this;
            frm.Show();
        }