Hello all,

i am in need of developing an application (writing a C/c++ code ) to Run an application(say for example a vlc player or any as such) from the Code and get its process ID and perform certain manipulation and then kill it .....

i want the application to run both in windows and Linux too..

Anyone here suggest me how to do this....

i heard like "system" command would be of help

i have been googling for good tutorials but no help..

Anyone here guide me...

any help is highly appreciated

thanks and regards

Hello all,

i am in need of developing an application (writing a C/c++ code ) to Run an application(say for example a vlc player or any as such) from the Code and get its process ID and perform certain manipulation and then kill it .....

i want the application to run both in windows and Linux too..

Anyone here suggest me how to do this....

i heard like "system" command would be of help

i have been googling for good tutorials but no help..

Anyone here guide me...

any help is highly appreciated
use following code and give your file path in function Shell Execute(compiled on DevC++ compiler)
thanks and regards

#include <cstdlib>
#include <iostream>
#include <windows.h>

using namespace std;

int main(int argc, char *argv[])
{
    ShellExecute(NULL, NULL, ("E:/AutoGordianKnot.2.55.Setup.exe"), NULL, NULL, SW_SHOWNORMAL);
    system("PAUSE");
    return EXIT_SUCCESS;
}
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.