Qt Code:
  1. QStringList Destinataires::getDestList()
  2. {
  3. int rowCount = model->rowCount();
  4. int i;
  5.  
  6. QItemSelectionModel *sel = qDestin->selectionModel();
  7. for( i = 0; i < rowCount; i++ )
  8. if ( sel->isRowSelected( i, qDestin->rootIndex() ) )
  9. s = model->data( model->index( i, 0 ) ); <- compile error
  10. rows.push_back( s );
  11. return rows;
  12. }
To copy to clipboard, switch view to plain text mode 

Qt Code:
  1. 96 C:\Qt\test\sms\destin.cpp no match for 'operator=' in 's = *(((Destinataires*)this)->Destinataires::model->QAbstractItemModel::_vptr$QObject + 68u)(((const QModelIndex&)((const QModelIndex*)(&*(((Destinataires*)this)->Destinataires::model->QAbstractItemModel::_vptr$QObject + 48u)(i, 0, ((const QModelIndex&)((const QModelIndex*)(&QModelIndex()))))))), 0)'
To copy to clipboard, switch view to plain text mode 

What should I do to retrieve the QString s from the model ?