how can I know the position of the mouse's cursor??
as the title,
I use Visual C++ language,
is there any way to get the position of mouse''s cursor?
#include <windows.h>#include <stdio.h>int main(int argc,char *argv[]){ POINT p; if(GetCursorPos(&p)){ printf("Cursor is at %i,%i\n",p.x,p.y); return 0; }else{ printf("Couldn't get cursor position\n"); return -1; }}
[edited by - TravisWells on May 20, 2004 1:06:48 PM]
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement