コード例 #1
0
        private void listView1_SelectedIndexChanged(object sender, EventArgs e)
        {
            try
            {
                if (deleteMode)
                {
                    var confirm = new DialogConfirm();
                    confirm.setDialogText("Are you sure you want to delete this customer? This action cannot be undone.");
                    confirm.ShowDialog();

                    if (confirm.DialogResult == DialogResult.Yes)
                    {
                        //master.deleteUser();
                        deleteMode = false;
                    }
                }
                else
                {
                    var person = listView1.SelectedItems[0].Text;
                    var search = new Search.SearchThroughAccount();
                    search.ForExactAccountNumber(master.getMasterBank().getBankServices(), long.Parse(person));

                    master.setAccount(search.AccountSearchResults[0]);
                    master.updateView(1);
                }
            } catch { }
        }
コード例 #2
0
        private void button2_Click(object sender, EventArgs e)
        {
            var confirm = new DialogConfirm();

            confirm.ShowDialog();

            if (confirm.DialogResult == DialogResult.Yes)
            {
                master.updateView(10);
            }
        }
コード例 #3
0
ファイル: Wizard.cs プロジェクト: micahjjohnson/MockBank
        private void cancel_Click(object sender, EventArgs e)
        {
            var confirm = new DialogConfirm();

            confirm.ShowDialog();

            if (confirm.DialogResult == DialogResult.Yes)
            {
                this.DialogResult = DialogResult.Cancel;
                masterForm.updateView(10);
            }
        }
コード例 #4
0
        private void closeAccount_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
        {
            var confirm = new DialogConfirm();

            confirm.setDialogText("Are you sure you want to close this account? This action cannot be undone.");
            confirm.ShowDialog();

            if (confirm.DialogResult == DialogResult.Yes)
            {
                masterForm.getMasterBank().getBankServices().closeAccount(masterForm.getAccount());
                masterForm.updateView(0);
            }
        }