Example #1
0
        private void Back_button_Click(object sender, EventArgs e)
        {
            this.Hide();
            var MA = new ManageAssets(LoggedInUser);

            MA.Closed += (s, args) => this.Close();
            MA.Show();
        }
Example #2
0
        private async void Login_button_Click(object sender, EventArgs e)
        {
            Employee login = await checkLogin(username_box.Text, password_box.Text);

            if (login != null)
            {
                this.Hide();
                var MA = new ManageAssets(login);
                MA.Closed += (s, args) => this.Close();
                MA.Show();
            }
            else
            {
                MessageBox.Show("invalid login", "eh", MessageBoxButtons.OK, MessageBoxIcon.Information);
            }
        }