problems with Dojo ComboBox on iPhone, Android

2875
4
01-16-2014 11:44 AM
deleted-user-ugCMpXci8bn5
New Contributor III
I wrote a webapp that executes an ArcGIS JS query from the selections of three Dojo ComboBox dropdown menus.  The last ComboBox is populated by a Dijit ItemReadFileStore (which is populated by another ArcGIS JS query), which creates a long list of names.  I am using the JS API 3.4.

This all works fine on a desktop (and on a Windows phone), but the dropdown menu is having problems on both an iPhone (IOS6) and an Android phone (v4.2.2).  When I click the down arrow, the keyboard pops up and hides most of the dropdown (the screen does not resize for the dropdown menu), and there is no scroll bar in the dropdown list, so essentially the list choices are not accessible.

I have tried to use a native HTML select element instead of the Dojo element, but I have not been able to get the ItemReadFileStore to populate the dropdown menu this way (I just get an empty box).  This isn't idea anyway, b/c I would like if possible to keep the autocomplete functionality and the placeholders that I am now using.

I tried the Dojo FilteringSelect element, but got the same results.  I get a parse error when I tried Dijit Select. 

I have read comments online from other developers who have had problems with the Dojo ComboBox on iPhones.  I am hoping that I don't have to rewrite my query results->store->combobox dtropdown ... but any sort of workaround or ideas are appreciated!

some code:

store:


 var dataItems = {
  identifier : 'name',
  label : 'name',
  items : values
 };

 var menuStore = new dojo.data.ItemFileReadStore({
  data : dataItems,
  clearOnClose : true
 });

 dijit.byId("schoolMenu").set("store", menuStore);


html:
<select id="Select"  forceValidOption="false"   data-dojo-type="dijit.form.ComboBox"  autoComplete="true" value="" placeholder="  Select" class="comboBoxClass1"   onchange= "setName(this)"  >
0 Kudos
4 Replies
deleted-user-ugCMpXci8bn5
New Contributor III
I never did find a solution for this, other than to switch to a native Select dropdown when using mobile devices ...
0 Kudos
TracySchloss
Frequent Contributor

Could you supply a bit of your code?  My users seem to be able to use the comboBox, they just don't like it. 

0 Kudos
PeggyCorey
New Contributor

Dojo Combobox problems...

I've included the dijit/form/ComboBox in my webapp, and Jason did above.  It appears to be working properly on my PC in IE, Firefox and Chrome.  But on Andrioid and IOS devices, the combobox seems to be having a lot of problems. 

When typing in the combobox, the list appears (most of the time) to be one letter behind the user, not recognizing the user's last keystroke, making it very difficult to properly go to and select the desired list item.  It appears to select the 1st entry in the one-letter-behind-version of what you've typed, within the selection anchors (inside the combobox), then when you try correcting it by typing the correct letter over the selection anchor's entry, it does not recognize your keystroke. 

The combobox also does not display a scroll bar, and the list is showing above rather than below the combobox.

I could take Jason's approach, and switch to a native Select dropdown when using mobile devices, but I don't want to because I'm trying to achieve responsive design.

Has anyone successfully employed a combobox, and had it work properly on IOS and Android devices?

Thank you!

0 Kudos
TracySchloss
Frequent Contributor

I switched to a native HTML select as well.   I found it to works in more situations than either dojo/ComboBox or FilteringSelect.

0 Kudos