Beispiel #1
0
        private void returnBookToolStripMenuItem_Click(object sender, EventArgs e)
        {
            if (ActiveMdiChild != null)
            {
                ActiveMdiChild.Close();
            }
            frmBookReturn bookReturn = new frmBookReturn();

            bookReturn.Show();
            bookReturn.MdiParent = this;
        }
        private void btnSelect_Click(object sender, EventArgs e)
        {
            if (lvBookReturn.SelectedItems.Count == 0)
            {
                MessageBox.Show("Please select a book to return", "Return Book",
                                MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
                return;
            }

            GlobalVariable.selectedIssueID = int.Parse(lvBookReturn.SelectedItems[0].SubItems[1].Text);

            if (ActiveMdiChild != null)
            {
                ActiveMdiChild.Close();
            }
            frmBookReturn bookReturn = new frmBookReturn()
            {
                MdiParent = MdiParent
            };

            bookReturn.Show();
            //bookReturn.MdiParent = this;
        }