... SetForegroundWindow(w_target); r=PostMessage(w_target,WM_MOUSEMOVE,0,0); printf("%d\n",r); //Выводит 1 ...