I have list of staff in database and it has more than 1000 records I created a Dropdown in Infopath but searching a record through Dropdown from more than 1000 record is very time consuming.

what I want is that instead if I can create a Textbox in Infopath that gets data from database list onkeyup of my Textbox it should bring name of staff from list as I type the names.

if it brings hints like Google search it would be better.

  • You can use search services and then create a basic search site or enterprise search site and then you can use this content to crawl or you can crawl external DB also. Then you can use search suggestions provided by SharePoint. If any keywords searched more than six times its automatically added into search suggestions. Also you can manually add keywords to get suggested. Jun 26, 2017 at 6:21

2 Answers 2


Marc D. Anderson has written a blog post named Using SPServices with jQueryUI’s Autocomplete Function on InfoPath Forms in SharePoint

This should help, but as it was written in 2011.. I'm assuming it was for SharePoint 2010 and InfoPath 2010.. But give it a try maybe it works for SharePoint 2013 as well..

The magic is done by script (using SPServices)

window.onload = function() {   window.setTimeout(readyCall, 1000); }

function readyCall(){

  var externalParties = [];

    operation: "GetListItems",
    listName: "External Parties",
    CAMLViewFields: "",
    async: false,
    completefunc: function (xData, Status) {
      $(xData.responseXML).SPFilterNode("z:row").each(function() {
    }   });

  //<input tabIndex="0" title="" class="q_zwfUqJo2fRthHnM4_0 as_zwfUqJo2fRthHnM4_0b9_zwfUqJo2fRthHnM4_0" id="ctl00_m_g_a226da68_1383_40e3_8410_1ada27d49dcf_FormControl0_V1_I1_T2" aria-invalid="true" style="position: relative;" onfocus="return (TextBox.OnFocus(this, event));" onblur="return (TextBox.OnBlur(this, event));" onpropertychange="return (TextBox.OnPropertyChange(this, event));" type="text" OriginalId="V1_I1_T2" FormId="ctl00_m_g_a226da68_1383_40e3_8410_1ada27d49dcf_FormControl0" ViewDataNode="3" direction="ltr" wrapped="true" ScriptClass="TextBox" VCARD_NAME="91161f891e59461042587839b2504693728ce05a" ?=""/>

$("input[id$='FormControl0_V1_I1_T2'], input[id$='FormControl0_V1_I1_T3']").autocomplete({
    source: externalParties,
    minLength: 3

There are few possible solutions for it and as most of the solution are client scripts it will work for Infopath as it is also converted into ordinary markup just like any other page.

  1. First Solution is using SPService and script provided in Using SPServices with jQueryUI’s Autocomplete Function on InfoPath Forms in SharePoint. It uses Jquery Autocomplete function along with SPServices.

  2. SPServices also has Autocomplete function which can be used for it.See this blog

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.