コード例 #1
0
        private void button2_Click(object sender, EventArgs e)
        {
            main m = new main();

            this.Hide();
            m.ShowDialog();
        }
コード例 #2
0
        private void logoutToolStripMenuItem_Click(object sender, EventArgs e)
        {
            DialogResult res = MessageBox.Show("Are you sure you want to Logout ?!", "Caution", MessageBoxButtons.OKCancel, MessageBoxIcon.Warning);

            if (res == DialogResult.OK)
            {
                this.Hide();
                main m = new main();
                m.ShowDialog();
            }
            else
            {
                MessageBox.Show("Operation is Cancelled....");
            }
        }