Beispiel #1
0
        private void btn_AddCard_Click(object sender, EventArgs e)
        {
            Enabled = false;
            var frmAddCard = new SetCard(Uow)
            {
                Text = @"Add new card"
            };

            frmAddCard.FormClosed += (o, args) => { Enabled = true; };
            frmAddCard.BringToFront();

            frmAddCard.Show();
        }
Beispiel #2
0
        private void btn_EditCard_Click(object sender, EventArgs e)
        {
            if (lstView_Results.SelectedItems.Count != 1)
            {
                return;
            }
            Enabled = false;

            var frmEditCard = new SetCard(Uow, SetCardFromListItem(lstView_Results.SelectedItems[0]))
            {
                Text = @"Edit card"
            };

            frmEditCard.FormClosed += (o, args) => { Enabled = true; };
            frmEditCard.BringToFront();

            frmEditCard.Show();
        }