Thread: calling an external program

  1. #1
    Registered User
    Join Date
    Feb 2004
    Posts
    1

    Wink calling an external program

    I have a C++ program, and I also have an exe that was not compiled from C++. I want my C++ program to call (execute) the exe program. The C++ program can end when the exe is run. Can someone tell me how to do it ?

    Thanks to those who provided the answer!
    Last edited by pshuster; 02-21-2004 at 08:18 PM.

  2. #2
    End Of Line Hammer's Avatar
    Join Date
    Apr 2002
    Posts
    6,231
    Read the FAQ, your answer is in there.
    When all else fails, read the instructions.
    If you're posting code, use code tags: [code] /* insert code here */ [/code]

  3. #3
    Registered User
    Join Date
    Nov 2001
    Posts
    1,348
    There are several solutions for the Win32 platform including CreateProcess() and ShellExecute().

    Kuphryn

  4. #4
    Carnivore ('-'v) Hunter2's Avatar
    Join Date
    May 2002
    Posts
    2,879
    x-( there's a thread right next to this one with a question almost identical...
    Just Google It. √

    (\ /)
    ( . .)
    c(")(") This is bunny. Copy and paste bunny into your signature to help him gain world domination.

  5. #5
    Registered User major_small's Avatar
    Join Date
    May 2003
    Posts
    2,787
    ^ yeah, I thought I was looking at This Post when I came here
    Join is in our Unofficial Cprog IRC channel
    Server: irc.phoenixradio.org
    Channel: #Tech


    Team Cprog Folding@Home: Team #43476
    Download it Here
    Detailed Stats Here
    More Detailed Stats
    52 Members so far, are YOU a member?
    Current team score: 1223226 (ranked 374 of 45152)

    The CBoard team is doing better than 99.16% of the other teams
    Top 5 Members: Xterria(518175), pianorain(118517), Bennet(64957), JaWiB(55610), alphaoide(44374)

    Last Updated on: Wed, 30 Aug, 2006 @ 2:30 PM EDT

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. having some trouble calling a function in the main program
    By CMakesMeSad :( in forum C Programming
    Replies: 19
    Last Post: 06-26-2009, 09:33 PM
  2. Program Plan
    By Programmer_P in forum C++ Programming
    Replies: 0
    Last Post: 05-11-2009, 01:42 AM
  3. Simple Timer, Call external program,
    By bliss in forum C++ Programming
    Replies: 2
    Last Post: 06-02-2005, 11:21 PM
  4. calling programs from a c++ program
    By md4u in forum C++ Programming
    Replies: 0
    Last Post: 05-04-2003, 07:39 AM
  5. calling c++ program from a webpage
    By Unregistered in forum C++ Programming
    Replies: 1
    Last Post: 10-04-2001, 09:41 AM