Assuming you have an "answer". You can get its index from List<String> choices .
int answerIndex = choices.indexOf(answer); simpleComboBox.select(answerIndex);
Or you can directly use simpleComboBox.select(answer); in case of String
If you want to show the default text, you can use
simpleComboBox.setEmptyText("Select an answer....");
source share