>Paul,
>
>This had no effect. The application stays open.
That's the Windows-friendly way to close an app; that should normally be the way you ask an application to close. You can force it to close using code like (using the previous code to get the hWnd handle), take a look at the thread Sergey posted.