Show "AutoComplete" suggestion list on Button Click - AJAX (ASP.NET)

Hi,

I have the following items on my web form:

1) TextBox
2) AutoCompleteExtender
3) Button

By default, if i type something in the "TextBox" then "AutoCompleteExtender" will show the suggestions. I want the suggestions list to show up when i clicked on "Button" not by default when i type in "TextBox". Can you please provide me the code for this functionality. Similary for closing the suggestion list also.

Thanks
milani_lucieAsked:
Who is Participating?

Improve company productivity with a Business Account.Sign Up

x
 
existenz2Connect With a Mentor Commented:
In your aspx for the AutoCompleteExtender tag:

Enabled="False"

and in your codebehind in the event from the button:

AutoCompleteExtender1.Enabled = true;

Or better said <ID of AutoCompleteExtender>.Enabled = true;
0
 
existenz2Commented:
Disable the AutoCompleteExtender by default and only enable it by setting the Enabled property when the button is clicked.
0
 
milani_lucieAuthor Commented:
Can you please provide me "JavaScript" code to do this ? Thanks
0
 
milani_lucieAuthor Commented:
Can we do with "JavaScript" ?
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.