Skip to main content
gamedev.net
🔒 Locked

close a program?

Started by 101 May 15, 2003 at 5:14 PM 1 replies 650+ views
Original Post
101
101
Quick question I need to know how to close another program in my program with only the name of the other program. any help is appriciated
mond
mond
Assuming you''re on Windows, a possible suggestion :

1) Call EnumProcesses(); search for your process name.
2) Lookup the process ID. Call OpenProcess().
3) Call TerminateProcess() with the handle returned from OpenProcess().
101
101
Thx; I''ll try those

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.