dgv.AllowUserToAddRows = false;
dgv.AllowUserToDeleteRows = false;
dgv.AllowUserToResizeRows = false;
dgv.AutoSizeColumnsMode = DataGridViewAutoSizeColumnsMode.AllCells;
dgv.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.AutoSize;
dgv.SelectionMode = DataGridViewSelectionMode.FullRowSelect;
dgv.ReadOnly = true;
dgv.ShowEditingIcon = false;
dgv.AllowUserToDeleteRows = false;
dgv.AllowUserToResizeRows = false;
dgv.AutoSizeColumnsMode = DataGridViewAutoSizeColumnsMode.AllCells;
dgv.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.AutoSize;
dgv.SelectionMode = DataGridViewSelectionMode.FullRowSelect;
dgv.ReadOnly = true;
dgv.ShowEditingIcon = false;