PyQt5 – Setting current index in ComboBox
In this article we will see how we can select the item at the specific index. By default when we create a combo box it shows the first item to be selected but we can change the index, in order to do this we will use
Syntax : combo_box.setCurrentIndex(index)
Argument : It takes integer as argument
Action performed : It will set item of given index
Below is the implementation –
Attention geek! Strengthen your foundations with the Python Programming Foundation Course and learn the basics.
To begin with, your interview preparations Enhance your Data Structures concepts with the Python DS Course. And to begin with your Machine Learning Journey, join the Machine Learning – Basic Level Course