Im trying to add a String to a javafx comboBox but i keep getting the above error :/
no suitable method found for add(String) method Collection.add(CAP#
Simply declare the room_id field in your controller class as
room_id
@FXML private ComboBox room_id;
If you're using
@FXML private ComboBox> room_id;
room_id.getItems() returns a ObservableList> i.e. a ObservableList with unknown element type and String cannot be assigned to this type.
room_id.getItems()
ObservableList>
ObservableList
String