I am using Sharepoint 2013. I have an "A" list with a lot of data in 2 column. Column "A1" is the name of the item and "A2" is the ID of the item. In the list "B" there are a lot of columns and the user can create new items. I would like to make the user able to have 2 text (or maybe dropdown) field. If the user starts to write in the "Field1" a list appear and the user can select an element from the "A1" column. If the user selected it, the "Field2" automaticaly filled with the same item's ID from the "A2" column. Or the user can do the same with the "Field2" so if the user choose the ID, the name of the item appears in the "Field1".

In short I would like to add two element by selecting one, but the user is free to choose to use the name or the ID of the item.

Any userfriendly method what result the same is good for me.

Thank you very much for any suggestion!

1 Answer 1


This functionality is referred to as "autocomplete", and can be done via javascript. The SPServices library has a function to do this, though it is designed to work with one field at a time. You'd need to wire up both fields for autocomplete, then write a little more code to set the value of the other field when an item is chosen for the current field.

Another option that doesn't require code is infopath. This wouldn't provide the functionality of providing options when the user starts to type, but could provide a drop-down of choices, and when one was picked, it could update the other field.

  • I don't have much experience yet, but I belive I can deal with it from this point. Thank u very much for the clear instructions!
    – Nefri
    Commented Sep 12, 2017 at 14:12
  • I tryed to add the autocomplete function to a simple textbox by useing the following code:
    – Nefri
    Commented Sep 15, 2017 at 12:58
  • <script language="javascript" src="/JS/jquery-1.6.2.min.js" type="text/javascript"></script> <script language="javascript" src="/JS/jquery.SPServices-0.7.2.min.js" type="text/javascript"></script> <script type="text/javascript"> $(document).ready(function () { $().SPServices.SPAutocomplete({ sourceList: "Empl", sourceColumn: "Emp", columnName: "Emp", ignoreCase: true, numChars: 2, slideDownSpeed: 'fast' }); });</script>
    – Nefri
    Commented Sep 15, 2017 at 12:59
  • I changed only the field names. But when I save the script editor I can see an rerror message for a sec: "AsyncDeltaManager.ParseErrorExeption: The messege recived from the server could not be parsed". And not working at all. The source code is from here: c-sharpcorner.com/UploadFile/sagarp/… Do u have any suggestion what can be wrong?
    – Nefri
    Commented Sep 15, 2017 at 13:06
  • Please post this as a new question.
    – Mike2500
    Commented Sep 15, 2017 at 13:36

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.