False cursor location on form

PL_Andrev

New member
Joined
Oct 9, 2016
Messages
2
Programming Experience
Beginner
Hi,

Making first steps at GDI and have problem - the location of mouse does not match to currently shown.
I suppose that problem is also connected with actual resolution (changeable width of menu bar).

How to correct the result? The true values should be shown near 0,0...

RA4lBy2.png
 
MousePosition is a screen coordinate, use PointToClient method to translate it.
 
Back
Top