private void btnUpdate_Click(object sender, EventArgs e)
 {
     if (AccountOrPosition)
     {
         int id       = int.Parse(dgUserAccount.SelectedCells[0].FormattedValue.ToString());
         var _account = GloblMain.dbo.Users.Find(id);
         if (_account == null)
         {
             return;
         }
         else
         {
             UserRegistration user = new UserRegistration(_account);
             user.ShowDialog();
         }
     }
     else
     {
         int id        = int.Parse(dgPositons.SelectedCells[0].FormattedValue.ToString());
         var _position = GloblMain.dbo.Positions.Find(id);
         if (_position == null)
         {
             return;
         }
         else
         {
             PositonViewW positonView = new PositonViewW(_position);
             positonView.ShowDialog();
         }
     }
     Refresh();
 }
        private void AddStudent_Click(object sender, EventArgs e)
        {
            if (AccountOrPosition)
            {
                UserRegistration user = new UserRegistration();
                user.ShowDialog();
            }
            else
            {
                PositonViewW positonView = new PositonViewW();
                positonView.ShowDialog();
            }

            Refresh();
        }