This function sets the pointer position.
#define INCL_WINPOINTERS /* Or use INCL_WIN, INCL_PM, */ #include <os2.h> HWND hwndDeskTop; /* Desktop-window handle. */ LONG lx; /* x-position of pointer in screen coordinates. */ LONG ly; /* y-position of pointer in screen coordinates. */ BOOL rc; /* Pointer position updated indicator. */ rc = WinSetPointerPos(hwndDeskTop, lx, ly);