We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

Cursor location reflect to control

Hi,

I always get the position of cursor reflect to rendered cell is always beyond the control

This code below is run when cell is activated.
my snippet code :

Control control = grid.CurrentCell.Renderer.Control;
if (control != null){
Point point = control.PointToClient(Cursor.Position);
}

The content of the variable point is always out of the area of the control. can u give me any suggestion to get the correct position of the cursor reflect to control.

Thanks in advance,
Wirawan

5 Replies

AD Administrator Syncfusion Team September 29, 2006 11:32 AM UTC

Hi Wirawan,

I have created the sample as per your requirement. The Attached will helps you to get the grid/ child control points from the Cursor.Position and let me know if you are looking something different.

Sample : http://www.syncfusion.com/Support/user/uploads/CursorPoint_6d5d48d8.zip

Thanks,
Haneef


AD Administrator Syncfusion Team October 2, 2006 01:21 AM UTC

Hi Haneef,

The solution you gave didnot include form1.cs.

Regards
Wirawan


NW Ngurah Wirawan October 3, 2006 01:03 AM UTC


Hi Haneef,

Could u repost again the solution, because it didnot include form1.cs.

Regards,
Wirawan


AD Administrator Syncfusion Team October 3, 2006 04:07 AM UTC

Hi Wirawan,

Sorry for the inconvenience caused.

Here is a sample.
http://www.syncfusion.com/Support/user/uploads/CursorPoint_ccde85aa.zip

Let me know if this helps.
Best Regards,
Haneef


NW Ngurah Wirawan October 3, 2006 05:56 AM UTC


Hi Haneef,

I still get wrong cursor location reflect to control. Here I attached my code to your solution, please click the currency cell and look on the caption of the form the position of the cursor reflect to activated control.

Regards,
Wirawan


Cursor location.zip

Loader.
Live Chat Icon For mobile
Up arrow icon