When mouse enters a cell, I need to pop up a form just besides the cell, like, the top left of the form is at the bottom right of the form.

But the following code doesn't work, where the form appear radomly..

How to do it right?

vb.NET Code:
  1. Private Sub m_dgvBasicDataGrid_CellMouseEnter(ByVal sender As System.Object, ByVal e As System.Windows.Forms.DataGridViewCellEventArgs) Handles m_dgvBasicDataGrid.CellMouseEnter
  2.      Dim pt As System.Drawing.Point
  3. Dim rect As Rectangle = m_dgvBasicDataGrid.GetCellDisplayRectangle(e.ColumnIndex, e.RowIndex, True)
  4. pt = New System.Drawing.Point(rect.Right, rect.Bottom)
  5.  
  6.  Form2.Location = pt
  7. Form2.Visible = True
  8. End Sub