[comp.windows.ms.programmer] Controlling other applications

tst@spica.hut.fi (Timo Veijola) (02/13/91)

It's easy to start an other application (eg. notepad) from your own code
using WinExec() or LoadModule() but how to you resize, move or delete
the other applications window ?

I have tried following ways but with no success:

- Retrieve the window handles of all windows on the screen using 
  hWnd=GetWindow(). GetWindowText(hWnd...) gives the caption titles OK.
- SendMessage(hWnd ...) does not seem to work. Propably the message is
  only delivered the my own applications message queue ...
- DestroyWindow(hWnd) has no effect ?



Timo Veijola
timo@aplac.hut.fi
Circuit Theory Laboratory
Department of Electrical Engineering
Helsinki University of Technology