Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted by Troy on Dec 18, 2009 15:57
open dhtmlx forum
dhtmlXCombo & enableFilteringMode: Does not display results until the user types a char.

dhtmlXCombo & enableFilteringMode: Does not display results until the user types a char.

I was wondering if there is a way to force the dropdown on an XML loaded combo to show value before a char is type.

Please let me know if you have a solution for this or if it is even possible.

Thanks
Troy
Answer posted by Alex (support) on Dec 21, 2009 01:35

Please check the sample http://www.dhtmlx.com/docs/products/dhtmlxCombo/samples/04_filtering/02_combo_filter.html

The first 3 combos are in filtering mode (the last two are loaded dinamically). These 3 combos show display all options in their lists if no character is typed.

Please explain the issue in detail 

Answer posted by Troy on Dec 21, 2009 07:20
The problem I'm having is when trying to loading the list dynamically.

        var a = new dhtmlXCombo("combo_zone", "propertyNumber", 200);
        a.enableFilteringMode(true, "BHEPServ?controllerId=CDTController&methodId=loadPropertyData", true, true);

I would like a list to be returned if nothing is typed.  I have tried to load the list with all the items directly in html but the list take way to long to load because I have nearly 4000 records.

Thanks
Troy
Answer posted by Alex (support) on Dec 21, 2009 08:17

In order to prepopulate combo you can call loadXML method with a path to a script that returns the default options:

var a = new dhtmlXCombo("combo_zone", "propertyNumber", 200);
a.enableFilteringMode(true, "BHEPServ?controllerId=CDTController&methodId=loadPropertyData", true, true);

a.loadXML(url);