I have a combo box on a form that I created. This combo box displays an ID and a name together. I am writing the contents of the combo box to a database. So far it writes correctly when I use this piece of code

self.ui.residentComboBox.currentText()

Now what I want to be able to do is pull only the ID from the combo box instead of the ID and the name together. Can anyone help?