Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Shutting down OTHER applications from within Access.

Status
Not open for further replies.

DavidMark

Programmer
Feb 28, 2002
28
EU
Hi all, I am using the shell command to open an .exe file, that works
fine. The problem is I can't find a way of shutting down the .exe from
within Access. I assume an API call would do the trick. Any
suggestions?
Thanks
Dave

Detec123@aol.com
 
David,

You should mess around with your .exe file and see what keystrokes you need to close it down. Then you can return the .exe files application ID by using shell, as follows:

ApplicationID=Shell("Myfile.exe")

You can then switch to your .exe application using:

AppActivate(ApplicationID,1)

Then you will have to use SendKeys to shut it down.

I wish I had a decent example to show you but I've never really used these commands except Shell.

I suggest looking at the help files before messing with your code, just so you are sure what you are doing.


HTH

Andrew.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top