Qt Combox如何根据文本反查索引值?
qt吧
全部回复
仅看楼主
level 10
daohang96
楼主
比如combox两项,1.小明,2.小红。我知道一个小红,怎么获得2这个编号
2014年08月25日 10点08分
1
level 10
下水道画家
int QComboBox::findText ( const QString & text, Qt::MatchFlags flags = static_cast<Qt::MatchFlags> ( Qt::MatchExactly | Qt::MatchCaseSensitive ) ) const
返回的就是索引
2014年08月26日 01点08分
2
daohang96
谢谢!我试试
2014年08月26日 01点08分
level 6
比你姐夫帅丶
currentText
2014年08月27日 08点08分
3
1