Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct
QCombobox read varialble like int
-
Hi
I want to read data from my QComboBox to int variable but it's problem because QComboBox return QString. Is there any easy way to get this data as int?
-
@Creatorczyk
https://doc.qt.io/qt-5/qstring.html#toIntOr, if you put
int
s in originally, you might consider https://doc.qt.io/qt-5/qcombobox.html#setItemData to store the integer value in the data.