This question already has an answer here:
- Ensuring QProcess termination on termination of its parent QThread 2 answers
I was using QThreads in Qt where my need is to launch a command-line executable from within a Qt thread and run the same within the thread's context.
I have used the below mentioned code for the same which seems to be running fine. However, I wanted to know if this kind of usage is permitted since we are launching a QProcess from within a QThread.
void Help_Menu_Thread::run()
{
Insert_Log("INFO::Help file referred by Admin");
QProcess HelpStart;
HelpStart.execute("c:\\windows\\hh.exe LPRS_help.chm");
HelpStart.close();
}
Awaiting your response.
Regards,
Saurabh G.