There wasn't necessarily anything wrong with the last line, other than it would mean that Notepad would have to open under the place where you started the gesture drawing.
This would be a little more consistent:
acMoveWindow(acFindWindow(nil, "Untitled - Notepad"), nil, nil, 0, 0)hwndTarget is the internal identifier of the window itself (the handle for the window [hence "hwnd"]). Most S+ actions accept either the handle itself (which is a number Windows assigns to the window), or the coordinates of where the window is. if no hwnd is passed in, S+ will take the coordinates and get the window handle at that location.
So in my code above, I'm calling acFindWindow, which returns the hwnd for the matching window and passes it (the number) into acMoveWindow for the hwndTarget parameter. acMoveWindow then tells Windows to move the window with the handle returned by acFindWindow (Notepad), to the specified coordinates.