I am trying to set a people picker control to a user other than the current user. I have read the 1222 post and am unable to get that to work: https://community.nintex.com/docs/DOC-1222
I put this function in my custom JavaScript:
function setToPrimay() {
var ins = new NF.PeoplePickerApi('#' + 'cidRep');
ins.search('i:0#.w|xxxuserID').done(function (data) {
ins.add(data[0]);
}
The people picker Client ID JavaScript variable name is: cidRep.
The button has a client click of: NWF.FormFiller.Events.RegisterAfterReady(function () { setToPrimay(); });
(Of course I changed the domain and user ID above)
I also tried setting the people picker with no luck: NWF$("#"+cidRep).val('i:0#.w|xxxuserID');
Thanks for any assistance,
John