Getting desktop cursor position???

I'm trying to get the mouse cursor's position on the desktop. I'm using SetCapture() and ReleaseCapture() from my app. The only problem is that I can only get the CPoint coords from within my application window and not the coords from the desktop... well I get them but I'm getting numbers like 36667 and 32235.

Can anybody point me in the right direction? ...pun intended : )


Comments

  • : I'm trying to get the mouse cursor's position on the desktop. I'm using SetCapture() and ReleaseCapture() from my app. The only problem is that I can only get the CPoint coords from within my application window and not the coords from the desktop... well I get them but I'm getting numbers like 36667 and 32235.
    :
    : Can anybody point me in the right direction? ...pun intended : )
    :
    :
    :

    hiya don't know if this would work for desktop,maybe worth a try anyway, sorry can't help more.

    // to save point of coordinates
    CPoint cp;

    GetCursorPos( &cp ); // get cursor coordinates


Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories