I used to add items to QCombobox by saying:
QCombobox cbb;
cbb.addItem("Hello");
But if I try this I get the error:
QComboBox cbb;
QString * s = new QString("hallo");
cbb.addItem(s);
error: no matching function for call to 'QComboBox::addItem(QString*&)'
How can I solve this?
source
to share