The CreatorCon Call for Content is officially open! Get started here.

Auto complete in Reference Type Variable

vintotz
Tera Contributor

Hi Everyone, any idea on how to modify the auto complete feature in a reference type variable.

i have this issue with a variable referenced to sys_user table. it only allows you to enter first name of a user so that the auto complete will work.

is it possible to modify this so that it accept either first name or the last name of user ?

1 ACCEPTED SOLUTION

Put below in "variable attributes" in default value tab.



ref_auto_completer=AJAXTableCompleter,ref_ac_columns=first_name;last_name,ref_ac_columns_search=true,ref_ac_display_value=false



Mark Correct if it solved your issue or hit Like and Helpful if you find my response worthy.



attribute.png


View solution in original post

11 REPLIES 11

Vikas-Malhotra
Mega Guru

Hi Vin,



Please refer this link for details of Auto Complete:


Auto-Complete for Reference Fields - ServiceNow Wiki http://wiki.servicenow.com/index.php?title=Auto-Complete_for_Reference_Fields#gsc.tab=0



Hope you find it helpful.



Thanks and Regards,


Vikas Malhotra


Hi Vikas,


  base on the   suggestion of the link you provided


i tried to modify the dectionary entry in sys_user table and added the following values in the attribute field


      ref_auto_completer=AJAXTableCompleter,ref_ac_columns=first_name;last_name,ref_ac_columns_search=true,ref_ac_display_value=false


still it doesn't give the result i expected. what i want is if i type the last name "Tuter" then it will show "Abel Tuter".


Did You try just below ?


ref_ac_columns=last_name;


here's where i put the code



find_real_file.png