To simplify things and help our users to be more productive, we have archived the current forum and focus our efforts on helping developers on Stack Overflow. You can post new questions on Stack Overflow or join our Discord channel.
Hi everyone,I'm trying to use inbuilt editor of grid to update objectsgrid.setEditorEnabled(true);
it works fine. now i want to use comboBox to let user choose available items from database instead of letting him type.I tried this but it doesnt work, i still get textField.
ComboBox cb= new ComboBox(); List<Container> data = containerService.findAll(); BeanItemContainer<Container> bicCb= new BeanItemContainer<>(Container.class); bicCb.addAll(data); cb.setContainerDataSource(bicCb); cb.setItemCaptionMode(ItemCaptionMode.PROPERTY); cb.setItemCaptionPropertyId("name"); grid.getColumn("from.name").setEditorField(cb);
does anyone have any idea how to change textField of editor to comboBox or something else?