if we select anything in search box it should Selected in select box.

if we select anything in  search box it should display in select box. please tell me how to set this link with Jquery.
<html lang="en">
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width, initial-scale=1">
  <title>jQuery UI Autocomplete - Default functionality</title>
  <link rel="stylesheet" href="https://code.jquery.com/ui/1.12.1/themes/base/jquery-ui.css">
  <!-- <link rel="stylesheet" href="https:/resources/demos/style.css"> -->
  <script src="https://code.jquery.com/jquery-1.12.4.js"></script>
  <script src="https://code.jquery.com/ui/1.12.1/jquery-ui.js"></script>
  $( function() {
    var availableTags = [
    $( "#tags" ).autocomplete({
      source: availableTags
  } );
<div  style="float: left;">
  <label for="tags">Search box : </label>
  <input id="tags">

<div style="float: left;">
  <label for="tags">Select box: </label>
  <select >

Open in new window

kumar naikGraphic DesignerAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Chris StanyonWebDevCommented:
You will need to hook into the select event. This fires when you choose an item from the AutoComplete. Give your <select> an ID (i.e #mySelect), and then add in the select event:

$( "#tags" ).autocomplete({
    source: availableTags,
    select: function( event, ui ) {

Open in new window

Obviously, this will only set the <select> if the item exists as an <option>
kumar naikGraphic DesignerAuthor Commented:
hi Sir can you give me a sample example so that i can check thankq
Chris StanyonWebDevCommented:
Sure - here's a link to a working demo: https://jsfiddle.net/ChrisStanyon/q57eouxv/

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
kumar naikGraphic DesignerAuthor Commented:
thank u my problem is solved
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today

From novice to tech pro — start learning today.