Allow user to filter combo box list by typing first few characters

3853
3
Jump to solution
03-28-2013 04:39 PM
MichaelBishopp
Occasional Contributor
I have a rather large (800+) domain list (street sign text) that I would like to put into an ArcPad combo box.  I am wondering if anyone has a solution (existing code) to filter the list while someone is typing.  In other words, as the user types in the first few words of the sign text, the domain list is filtered via a wildcard search and the list becomes shortened and more manageable to pick from.

FYI, the domain list is very random and does not really lend itself well to categorical organization.  I have thought of the solution of creating categories of signs and then filtering the list based on the user choosing a category and then just that category of signs shows in the list, but this just doesn't seem to be possible for this very unstructured list.

I have included a sample of the domain as a spreadsheet so that you can get a flavor of what I am dealing with.
Tags (3)
0 Kudos
1 Solution

Accepted Solutions
MichaelBishopp
Occasional Contributor
Just came across this oldish post. Ran into this issue last year too. I found that if you loaded the combobox with a .dbf for your domain values it would limit results based on the user typing in the first few characters. No need to write code around all the events of the combo box changing or anything. Hope this helps if you haven't already found the answer.

Ryan


Thanks Ryan,

Your solution worked with a caveat:  I have an axf, so the .dbf has to be relative to this axf to make it all go.  To make it work on the mobile device, make sure the .dbf is in the same directory as the .axf and then copy the entire project folder to the mobile device.  This will do the trick.  Also, when you type in the combo box, the list is not really filtered, but by typing you are automatically paged to the nearest match in the list.  Since my list is 800 values long, this is a big relief that I don't have to write code to make this work.

Awesome!

View solution in original post

0 Kudos
3 Replies
RyanSutcliffe
Occasional Contributor II
Just came across this oldish post. Ran into this issue last year too. I found that if you loaded the combobox with a .dbf for your domain values it would limit results based on the user typing in the first few characters. No need to write code around all the events of the combo box changing or anything. Hope this helps if you haven't already found the answer.

Ryan
0 Kudos
MichaelBishopp
Occasional Contributor
Just came across this oldish post. Ran into this issue last year too. I found that if you loaded the combobox with a .dbf for your domain values it would limit results based on the user typing in the first few characters. No need to write code around all the events of the combo box changing or anything. Hope this helps if you haven't already found the answer.

Ryan


Thanks Ryan,

Your solution worked with a caveat:  I have an axf, so the .dbf has to be relative to this axf to make it all go.  To make it work on the mobile device, make sure the .dbf is in the same directory as the .axf and then copy the entire project folder to the mobile device.  This will do the trick.  Also, when you type in the combo box, the list is not really filtered, but by typing you are automatically paged to the nearest match in the list.  Since my list is 800 values long, this is a big relief that I don't have to write code to make this work.

Awesome!
0 Kudos
EugeneDurshpek
New Contributor III
Thanks for this information.
Has anyone dealt with subtypes and default values as well as filtering combo boxes specific to each subtype value? I'm wondering how I can apply this method using the .dbf while using subtypes. Any thoughts?

Thanks!
Eugene D.
0 Kudos