Thanks so much Raghu for such a quick reply. 
Actually I am using a list and not a textbox and I do not want a suggest
list but just want to narrow down on the content of a populated drop
down list.

I'll explain... if I have a standard drop down list for country names
and the list includes ..., "Iceland", "India", ..., "Namibia"...
Now, if you press "I" at the drop down list you'll be taken to the first
element that starts with "I", which is Iceland. But, if you press "In",
you'll not be taken to the first element that starts with "In", which is
India, but to the first element that starts with "N", which is Namibia. 
This is the standard way a drop down list will.
The feature that I want is like recursive sort or narrowing down on the
elements of the list.

(If you want to try what I am talking about, just try creating an
account/user on any website and in the country drop down list try
choosing India. You may try hotmail. )

Thanks for your suggestion.

Regards,

Shivani

 

-----Original Message-----
From: Raghu Kanchustambham [mailto:[EMAIL PROTECTED] 
Sent: 30 January, 2006 4:54 PM
To: Struts Users Mailing List
Subject: Re: Narrow down on an element in a select list with every key
press

Shivani,
You may want to take a look at the suggest tag provided by
Struts-layout taglibrary.

http://struts.application-servers.com/suggest/index.html

I have personally used this tag and it is quite easy to get it
working. The best thing is that you do not need to write a single line
of Javascript. Everything is encapsulated into this Tag.

The example listed is very close to what you want. When you write your
"callback" Class (in the above example - CountrySuggestAction)  you
can decide the "list" that "qualifies" with your keypress.

Also I strongly recommend this set of tags to anyone who wants to have
some "rich" functionality and do not want to move to JSF. The tabs
functionality, interdependent combos, treeviews, sorting, paging etc
are very useful and easy to use. Besides as I understand from their
site this is mature for more than 5 years.

I have been using their tags and they ROCK ! :-)

HTH,
Raghu



On 1/30/06, Shivani Sawhney <[EMAIL PROTECTED]> wrote:
> Hi,
>
>
>
> Is it possible, through Struts or JavaScript, to narrow down on an
> element in a select list with every key press?
>
> I have a sorted select list for country names. If I have entries for
> "Iceland" and "India" in the pick list, then pressing "I" would take
me
> to "Iceland" but pressing "In" will take me to element starting with
"N"
> and not to "India". Is there any way that I can narrow down on an
> element in a select list with every key press?
>
> This functionality can well be achieved in applications but can this
be
> achieved in web based solutions. I don't mind using JavaScript too.
>
>
>
> Any help will be appreciated.
>
> Regards,
>
> Shivani
>
> ******************************************************************
>
> NetEdge Computing Global Services Private Limited.
>
> A-14, Sector-7, NOIDA U.P. 201-301
>
> Tel #  91-120-2423281, 2423282
>
> Fax #  91-120-2423279
>
> URL  http//www.netedgecomputing.com
>
> ******************************************************************
>
> This message may contain confidential and/or privileged information.
If
> you are not the addressee or authorized to receive this for the
> addressee, you must not use, copy, disclose or take any action based
on
> this message or any information herein. If you have received this
> message in error, please advise the sender immediately by reply e-mail
> and delete this message. Thank you for your cooperation
>
>
>
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]







---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to