private void buttonAdminLogin_Click(object sender, EventArgs e) { Verify(); string user = textBoxUser.Text.Trim(); string pass = textBoxPass.Text.Trim(); if (user == "spitaluser1" && pass == "spitalpass") { adminMain adminMain = new adminMain(); adminMain.Show(); this.Hide(); } else { textBoxUser.Clear(); textBoxPass.Clear(); MessageBox.Show("Datele introduse nu sunt corecte!", "Date incorecte.", MessageBoxButtons.OK, MessageBoxIcon.Error); return; } }
private void adminBtn_Click(object sender, RoutedEventArgs e) { adminMain adMain = new adminMain(); adMain.Show(); }