c++ - Windows Qt Invoke batch file and exit the App -
i developing application in windows8 using qt, need create updater it. have wrote update downloader part, , update script replace previous content newly downloaded data.
now need execute bat file application itself, , exit app before script executed, because script going remove dlls , application binary running.
how can resolve issue?
thanks haris
you can use qprocess::startdetached
run instance of command prompt batch file argument in new process , detach it. after should exit application :
qprocess::startdetached("cmd.exe", qstringlist() << "/c" << "path\\to\\mybat.bat"); qapp->quit();
Comments
Post a Comment