[Qt-interest] Qprocess - determining the state
Phil
phillor at telstra.com
Sat Dec 5 03:03:41 CET 2009
On Fri, 4 Dec 2009 06:31:52 pm Andre Haupt wrote:
> QProcess::ProcessState state = myProcess->state();
Thank you Andre, Stefano and Ross.
It turns out that knowing the state of the process is not the problem. My
simple application reads the standard output, as follows:
ui->textEdit->setText(myProcess->readAllStandardOutput());
Further reads are tacked onto the end of the text in the text edit box, which
is not what I want. What I was trying to do was to have the process stop
after the first read and a new process to start before subsequent reads.
I had tried clearing the text edit box before a read and terminating (I've
also tried kill as well) the process after a read. It seems that what I really
need to do is clear the standard output between reads. How do I do that?
--
Regards,
Phil
More information about the Qt-interest-old
mailing list