Hello!
In my program this function below is called once when I opened.
It read the file and updates the QLabel "title" with setText().

Qt Code:
  1. void Mpl::updateFiles()
  2. {
  3.  
  4. QFile file("mpl.dat");
  5. if (!file.open(QIODevice::ReadOnly | QIODevice::Text))
  6. return;
  7.  
  8. QTextStream in(&file);
  9. QApplication::setOverrideCursor(Qt::WaitCursor);
  10. while (!in.atEnd()) {
  11. QString line = in.readLine();
  12. uplist << line;
  13. }
  14. QApplication::restoreOverrideCursor();
  15. file.close();
  16. if (uplist.count() == 3){
  17. title->setText(uplist.at(0));
  18. path = uplist.at(1);
  19. path2 = uplist.at(2);
  20. }else{
  21. QMessageBox::warning(this, "Error reading File",
  22. "The file should contain: name of the project and paths.");
  23. }
  24. }
To copy to clipboard, switch view to plain text mode 

In the programme it is possible to change the file "mpl.dat". Then the user can click a QPushButton and call updateFiles () again. But the upgrade of QLabel "title" does not occur.
Someone help me, please?
Thanks