Drag Drop Between Listview and DataGridView

sapator

Member
Joined
Oct 4, 2006
Messages
23
Programming Experience
1-3
Hi.
I do a drag and drop operation between a Listview and a Datagridview.
The problem is that i cannot get the Cell coordinates when i drop the data since the
DataGridView_DragDrop event only pronides points(x,y) and i need rectangle coordinates for the datagridview Cell.

 
The e.x/e.y coordinates for DragDrop event is screen points, translate them to DGV points with the control.PointToClient method. With this client point you can use the DGV.HitTest method that will provide the info you need to determine cell.

Thread moved to Winforms Grids forum.
 
Back
Top