private void dataGridView4_CellMouseDoubleClick(object sender, DataGridViewCellMouseEventArgs e)
 {
     if (e.ColumnIndex >= 0 && e.RowIndex >= 0)
     {
         if (e.Button == MouseButtons.Right)
         {
             string       id           = this.dataGridView4[4, e.RowIndex].Value.ToString();
             DialogResult dialogResult = MessageBox.Show("Sei sicuro di voler eliminare questa riga?", "eliminazione", MessageBoxButtons.YesNo);
             if (dialogResult == DialogResult.Yes)
             {
                 db.esegui(string.Format("DELETE FROM prenotazioniCovid WHERE idpr = '{0}'", id));
                 caricaDati();
             }
         }
         else
         {
             string       id           = this.dataGridView4[5, e.RowIndex].Value.ToString();
             DialogResult dialogResult = MessageBox.Show("Vuoi vedere questo paziente?", "informazioni", MessageBoxButtons.YesNo);
             if (dialogResult == DialogResult.Yes)
             {
                 ViewUser view = new ViewUser(id);
                 this.Hide();
                 view.ShowDialog();
                 stampaPren();
                 this.Show();
             }
         }
     }
 }
        private void datiPazienti_CellMouseDoubleClick(object sender, DataGridViewCellMouseEventArgs e)
        {
            string id = this.datiPazienti[0, e.RowIndex].Value.ToString();

            if (e.Button == MouseButtons.Left)
            {
                ViewUser view = new ViewUser(id);
                this.Hide();
                view.ShowDialog();
                stampaPazienti();
                this.Show();
            }
        }