private void DataGV_MouseClick(object sender, System.Windows.Forms.MouseEventArgs e) { DataGridView.HitTestInfo hti = DataGV.HitTest(e.X, e.Y); if (hti.Type == DataGridViewHitTestType.RowHeader || hti.Type == DataGridViewHitTestType.Cell) { DataGV.CurrentCell = DataGV.Rows[hti.RowIndex].Cells[0]; if (e.Button == System.Windows.Forms.MouseButtons.Right) { DataGV.CurrentCell = DataGV.Rows[hti.RowIndex].Cells[0]; DataGVContextMenu.Show(this, e.Location); } string oGuid = DataGV.CurrentRow.Cells["Guid"].Value.ToString(); Helper.ZoomWindowAndHilight(oGuid); if (Helper._CurrentIndex != hti.RowIndex) { BtnUndo.Enabled = false; Helper._CurrentIndex = hti.RowIndex; } } }