0

I want to write a QString that includes two QProcess enums into a QTextBrowser. Therefore I used in one of my methods:

QString Text = "Error! Exit-Status: " + Status + QString(" Error-Code: ") + Prozess.error() + " File not created!"

Dialog.mytextBrowser -> setText(Text);

This also works, but the value of the QProcess::ExitStatus "Status" and the value of Prozess.error() are missing. What do I have to change to get the values into the QTextBrowser? greetings

Streight
  • 811
  • 4
  • 15
  • 28
  • 1
    You can bisect the problem by writing Text to QDebug and see if the information is in the string there, if it is not than the QTextBrowser is a red herring. – Andrew Tomazos Apr 05 '12 at 18:36
  • I used `qDebug() << Status << Prozess.error();` and it gave me the right values. – Streight Apr 05 '12 at 18:52
  • And what if you use `qDebug() << Text;` ? – Andrew Tomazos Apr 05 '12 at 19:26
  • Ok, problem was solved by `QString Text = QString( "Error! Exit-Status: %1 Error-Code: %2 File not created!" ).arg( Status ).arg(Prozess.error());` . Anyway, thx for the support. – Streight Apr 05 '12 at 22:01

1 Answers1

0

Ok, problem was solved by QString Text = QString( "Error! Exit-Status: %1 Error-Code: %2 File not created!" ).arg( Status ).arg(Prozess.error()); . Anyway, thx for the support.

Streight
  • 811
  • 4
  • 15
  • 28