cancel
Showing results for 
Search instead for 
Did you mean: 

iBrowser Auto-select while typing

Former Member
0 Kudos

Is there any way to select an iBrowser, type multiple characters, and have the selected result match the character string that you typed.

For example - Say I have the following list of items: eggplant, papaya, and pear. If I type "pe", the selected item will first be papaya, than eggplant. What I'm looking for is the selected item to be pear. If it makes a difference, I'm running IE6.

I've got a solution which I do not want to use where I have the user type into a textbox. As each character is pressed, the text of the textbox is passed as a parameter in to the SQL LIKE statement. Each time this query runs, the list is shortened. Obviously, I don't want to have to query the database every time somebody types a character, nor do I want the extra textbox. Any suggestions? Thanks in advance.

Eric

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Drop the iBrowser and use AJAX for this. There are a lot of examples on the web that can be modified to work with MII. Find one that has the particular UI features/behavior that you want.

Keep you result set sane and you shouldnt have any issues hitting the db multiple times(I use 10).

Edited by: Christian Libich on May 19, 2009 5:42 PM

Former Member
0 Kudos

While your AJAX solution would work, I was hoping to stick with the iBrowser. The application that I'm modifying was poorly written (not by me) and would require me to change code in several spots if I change the control from an iBrowser to an AJAX drop down menu.

Thank you for the suggestion though.

Former Member
0 Kudos

iBrowser out of the box will not do what you would like. And I understand not wanting to rewrite everything. I agree with Christian on the AJAX front, but if you choose not to do that, perhaps a little less painful might be switching the iBrowser to either:

1. a hidden iGrid that FirstUpdateEvent populates via JS a regular html select/option element, which should give you closer to what you are looking for.

2. a servlet with an xslt that creates the html select/option element.

Former Member
0 Kudos

Thank you for the other suggestions. Depending on how bad the users really want that functionality, I may just suck it up and re-code certain parts of the application using the AJAX dropdown menus. Thank you both for your help.

jcgood25
Active Contributor
0 Kudos

Full built-in / limited change options consider the following:

The iBrowser only supports key indexing, meaning pressing a key will jump you to that section (assuming an alpha sorted list) in the list.

Putting an html button between your input field and iBrowser 'LIKE' expression query search will at least avoid undesired queries that would be triggered by key events in your input box.

Regards,

Jeremy

Answers (0)