Thread: Closing other programs. (C++)

  1. #16
    Yeah, nice one! Works a treat! It'll do until I download the SDK..

    I'll probably have broadband by the end of the year, telstra (telecom) is lagging in my area but they just announced they are going to provide broadband to more rural areas, which is where I am.

    Thanks for all the help!

  2. #17
    Is there a way to detect when new processes start? I wish to wait until a program is started before I check to see if it is to be closed and then wait again for the next program to start.

  3. #18
    Yes, my avatar is stolen anonytmouse's Avatar
    Join Date
    Dec 2002
    Posts
    2,544
    By chance I made a utility that does what you want a couple of weeks ago.

    It does the following:
    Sends a close message to all windows associated with the process.
    Waits for the process to finish for timeout milliseconds.
    Terminates the process forcefully if it has not finished.
    Refreshes the system tray to get rid of its icons.

    Attached is exe and source code(in C).

    USAGE KillProcess module.exe timeout(in milliseconds)
    eg. KillProcess aol.exe 2000

    Acknowledgement: Some of the code is from the KillProc example by John Findlay available at:
    http://www.john.findlay1.btinternet....og/winprog.htm

  4. #19
    Registered User
    Join Date
    Sep 2005
    Posts
    3
    thanks.

  5. #20
    Registered User
    Join Date
    Sep 2001
    Posts
    4,912
    http://cboard.cprogramming.com/annou...ouncementid=51

    5. Don't bump threads. (Bumping: posting messages on threads to move them up the list).
    The thread was over 2 years old. Please do not post in threads that have been dead for more than a couple of weeks.

    Closed.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Interpreter.c
    By moussa in forum C Programming
    Replies: 4
    Last Post: 05-28-2008, 05:59 PM
  2. POSIX/DOS programs?
    By nickname_changed in forum C++ Programming
    Replies: 1
    Last Post: 02-28-2003, 05:42 AM
  3. Programs opening programs
    By LinuxPLC in forum C Programming
    Replies: 1
    Last Post: 11-21-2002, 12:50 PM
  4. executing c++ programs on the web
    By gulti01 in forum C++ Programming
    Replies: 4
    Last Post: 08-12-2002, 03:12 AM
  5. Closing Programs?
    By BubbleMan in forum C++ Programming
    Replies: 4
    Last Post: 09-22-2001, 09:33 PM