Qt Code:
  1. {
  2. naamDialog dlg(this);
  3. if( dlg.exec() == QDialog::Accepted ) {
  4. QString naam = dlg.leNaam->text();
  5.  
  6. for (int row = 0; row < list.count(); ++row) {
  7. naam = dlg.leNaam->text();
  8. list.append(naam);
  9. }
  10. }
To copy to clipboard, switch view to plain text mode 

I don't understand this. What are you trying to do. Is leNaam a QLabel, QLineEdit?
What are you trying to do in the for loop? It is incorrect, anyway. By appending something to the list you modify it's item count. Theoretically that for should be infinite.

Anyway, you were trying to add naam list.count() times... This doesn't make any sense..
Care to revise?