Get Help:Ask a Question in our Forums|Report a Bug|More Help Resources
Sign In| Join
Last post Jun 21, 2010 11:44 AM by mbanavige
Member
61 Points
100 Posts
Jun 20, 2010 03:05 PM|LINK
hi all,
I have a listbox with some values and a textbox when i enter "a" to the textbox all items which starts with "a"
should be shown and if i enter "ab" all the items with "ab" should be shown is there a way to do it
Thanks in advance
All-Star
130719 Points
14322 Posts
ASPInsiders
Moderator
MVP
Jun 20, 2010 03:10 PM|LINK
Did you want to do this just with a webforms postback approach (not recommended)
or how about using some client side code.
you could do this with an autocomplete ajax extender
http://www.asp.net/ajax/ajaxcontroltoolkit/Samples/AutoComplete/AutoComplete.aspx
there's also a number of jQuery autocomplete plugins too. for example:
http://bassistance.de/jquery-plugins/jquery-plugin-autocomplete/
Jun 21, 2010 11:05 AM|LINK
hi Mbanavige thanks for the replay i have all the data at page load and all the data will be listed in the list box and i dont need to use web service to get the data is there any other way other than this
Jun 21, 2010 11:44 AM|LINK
the autocomplete control here: http://jquery.bassistance.de/autocomplete/demo/ supports local data (a list of values embedded in your page and accessible to client script).
so you dont necessarily need to make a webservice call if you used it.
roma_victa
Member
61 Points
100 Posts
Selecting List box itam through textbox
Jun 20, 2010 03:05 PM|LINK
hi all,
I have a listbox with some values and a textbox when i enter "a" to the textbox all items which starts with "a"
should be shown and if i enter "ab" all the items with "ab" should be shown is there a way to do it
Thanks in advance
mbanavige
All-Star
130719 Points
14322 Posts
ASPInsiders
Moderator
MVP
Re: Selecting List box itam through textbox
Jun 20, 2010 03:10 PM|LINK
Did you want to do this just with a webforms postback approach (not recommended)
or how about using some client side code.
you could do this with an autocomplete ajax extender
http://www.asp.net/ajax/ajaxcontroltoolkit/Samples/AutoComplete/AutoComplete.aspx
there's also a number of jQuery autocomplete plugins too. for example:
http://bassistance.de/jquery-plugins/jquery-plugin-autocomplete/
roma_victa
Member
61 Points
100 Posts
Re: Selecting List box itam through textbox
Jun 21, 2010 11:05 AM|LINK
hi Mbanavige thanks for the replay i have all the data at page load and all the data will be listed in the list box and i dont need to use web service to get the data is there any other way other than this
mbanavige
All-Star
130719 Points
14322 Posts
ASPInsiders
Moderator
MVP
Re: Selecting List box itam through textbox
Jun 21, 2010 11:44 AM|LINK
the autocomplete control here: http://jquery.bassistance.de/autocomplete/demo/ supports local data (a list of values embedded in your page and accessible to client script).
so you dont necessarily need to make a webservice call if you used it.