Code: Select all
SetWindowPos_(hWnd,0,newx,newy,origw,origh,#SWP_NOSIZE)
Note: I've tried UpdateWindow_(), InvalidateRect_(), and all that sort of thing after the movement. Didn't help (or I did it wrong?).
BTW, I got the test window by opening a command prompt and entering: msg * test
Here's some test code - do the command prompt thing above, then run this and click the test window:
Code: Select all
Sleep_(2000)
SetWindowPos_(GetForegroundWindow_(),0,100,100,0,0,#SWP_NOSIZE)