ITsolutionWizard
asked on
jquery, populate, auto complete
http://www.aspsnippets.com/Articles/AJAX-AutoCompleteExtender-Example-in-ASPNet.aspx
I used above codes to get auto complete.and let us assume the above has text box name called fullname
when a fullname is selected, I want to populate to below text boxes.
is it possible? If yes, how to do that?
<input type="text" id="firstName"><br>
<input type="text" id="lastName"><br>
I used above codes to get auto complete.and let us assume the above has text box name called fullname
when a fullname is selected, I want to populate to below text boxes.
is it possible? If yes, how to do that?
<input type="text" id="firstName"><br>
<input type="text" id="lastName"><br>
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Thanks but I need sample with auto complete
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
here samples :
https://www.experts-exchange.com/questions/28004117/jQuery-AutoComplete-from-Database.html
https://www.experts-exchange.com/questions/26388514/JQuery-Auto-Complete-and-ASP-net.html
https://www.experts-exchange.com/questions/28688532/jquery-autocomplete.html
What you need to read carefully is the response part of the ajax call :
https://www.experts-exchange.com/questions/28004117/jQuery-AutoComplete-from-Database.html
https://www.experts-exchange.com/questions/26388514/JQuery-Auto-Complete-and-ASP-net.html
https://www.experts-exchange.com/questions/28688532/jquery-autocomplete.html
What you need to read carefully is the response part of the ajax call :
return{
label: item.Name,
value: item.Name
}
response( $.map( data, function( item ) {
return {
label: item.company,
value: item.company,
companyid: item.companyId
}
@leakim971 - How does that take the option the user selects and split it into two textboxes? The AJAX response has already resolved by that point -- since it's the AJAX that populates the list of options. The OP requires an event that fires when the user selects an option, not when autocomplete retrieves the options.
I've given the OP a solution that will work. The event will fire a function on OnClientItemSelected and the function splits the selected option, and copies the two results to the textboxes.
I've given the OP a solution that will work. The event will fire a function on OnClientItemSelected and the function splits the selected option, and copies the two results to the textboxes.
You should check my last question in my first answer and see how your solution gonna handle this simple case
so how do you want to know what is first and last name ? just a split ?
What is last and first name for the contactName "IT Solution Wizard" ?