Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

Defferent ways of launching new application from our applciation

Chaitanya_PuneChaitanya_Pune Member Posts: 87
I am using VC++ 6.0

How many ways are there to launch(execute) new application from our application.
I know WinExec,CreateProcess and ShellExecute.
Are there any other ways.
What is the difference in all these methods?
Which one to use in which situation?

Also let me know
What is the latest version of VC++ ?

Comments

  • stoberstober Member Posts: 9,765 ✭✭✭
    : I am using VC++ 6.0
    :
    : How many ways are there to launch(execute) new application from our application.
    : I know WinExec,CreateProcess and ShellExecute.
    : Are there any other ways.
    : What is the difference in all these methods?
    : Which one to use in which situation?
    :
    : Also let me know
    : What is the latest version of VC++ ?
    :

    system();
    exec family of functions

    >> What is the difference in all these methods
    CreateProcess() gives you the most control over the new processes, while the others do pretty much the same thing. exec family of functions are POSIX compliant (I think) and work on *nix as well.

    >> Which one to use in which situation
    Use CreateProcess() when you need the handle of the newly created process for some other purpose, when you want to change some of the charastics of the new process (such as disable the console window if its a console program), or when you do not want your program to be blocked while the new process is running. Otherwise, if you don't care about any of those things then you can use the easier-to-use other functions.

Sign In or Register to comment.