private void btngiris1_Click(object sender, EventArgs e)
        {
            //var staff = login(txtuser.Text, txtpassword.Text);
            //if (staff == null)
            //{
            //    MessageBox.Show("Şifre Yanlış");
            //}
            //else
            //{
            //    MessageBox.Show("Giriş Başarılı");
            //    personelmenu yonetim = new personelmenu();
            //    yonetim.Show();
            //    this.Hide();

            //}
            baglanti.Open(); SqlCommand komut = new SqlCommand("select * from Governance where UserName='******'and UserPassword='******'", baglanti); SqlDataReader dr = komut.ExecuteReader();
            if (txtuser.Text == "" || txtpassword.Text == "")
            {
                MessageBox.Show("Boş Alan Bırakılamaz !", "Giriş Başarısız", MessageBoxButtons.OK, MessageBoxIcon.Error);
            }
            else if (dr.Read())
            {
                yonetimenu menu = new yonetimenu(); menu.Show(); this.Hide();
            }
            else
            {
                txtuser.Clear(); txtpassword.Clear(); MessageBox.Show("Kullanıcı Adı Veya Şifre Yanlış !", "Giriş Başarısız", MessageBoxButtons.OK, MessageBoxIcon.Error);
            }
            baglanti.Close();
        }
        private void pictureBox1_Click(object sender, EventArgs e)
        {
            yonetimenu menu = new yonetimenu();

            menu.Show();
            this.Hide();
        }