In Qt, I can get the selected text of a QComboBox by using the
combobox->currentText()
method.
How can I get the selected value?
I checked over http://qt.nokia.com/doc/4.6/qcombobox.html for help but I couldn't find a method currentData()
which I expected to find. I could only find combobox->currentIndex()
Is there a smarter way to do it other than combobox->itemData(combobox->currentIndex())
?