private void Rooms_dgv_CellMouseUp(object sender, DataGridViewCellMouseEventArgs e)
 {
     if (e.ColumnIndex == Rooms_dgv.Columns["CheckboxColumn"].Index)
     {
         Rooms_dgv.EndEdit();
     }
 }
        //headerchckbox click event
        private void Headerchckboxclick(CheckBox Hcheckbox)
        {
            foreach (DataGridViewRow row in Rooms_dgv.Rows)
            {
                ((DataGridViewCheckBoxCell)row.Cells["checkBoxColumn"]).Value = Hcheckbox.Checked;
            }

            Rooms_dgv.RefreshEdit();
            Fill_checked_capacity();
        }