Hi Isomorphic ,
I am creating a simple combobox using the below code.
Above code works if I open by manualy clicking the combobox. It populates the correct listgrid of options in combobox. When I click directly on combobox and write something the option list opens as empty always. I've set the autofetch true so I can see the fetch call while rendering the grid. So data is available but typeahead is not working.
Any suggestions?
I am creating a simple combobox using the below code.
Code:
private ComboBoxItem getCodeDropDown(String fieldName) { final ComboBoxItem comboBox = new ComboBoxItem(); final DataSource dataSource = DataSource.get("MyDS"); comboBox.setPickListWidth(300); comboBox.setAllowEmptyValue(true); comboBox.setSortField(0); comboBox.setAddUnknownValues(false); comboBox.setAutoFetchData(true); comboBox.setOptionDataSource(dataSource); final Criteria criteria = new Criteria(); criteria.addCriteria("someType", 1L); comboBox.setOptionCriteria(criteria); final ListGridField nameField= new ListGridField("name", "Name"); nameField.setWidth(100); final ListGridField descField = new ListGridField("desc", "Description"); descField.setWidth(200); comboBox.setSortField("name"); comboBox.setPickListFields(nameField, descField); comboBox.setDisplayField("name"); comboBox.setValueField("name"); final ListGrid pickListProps = new ListGrid(); pickListProps.setSortField("name"); pickListProps.setDataFetchMode(FetchMode.BASIC); pickListProps.setCanHover(true); pickListProps.setShowHover(true); pickListProps.setLeaveScrollbarGap(false); comboBox.setPickListProperties(pickListProps); return comboBox; }
Any suggestions?
Comment