AnsweredAssumed Answered

Set a People picker value using JavaScript

Question asked by sarasafari on Dec 5, 2017
Latest reply on Dec 5, 2017 by shirin

Hi there,

I have a people picker filed on my form, it's ClientID is:ciMyPeople.  I want to fill it with different values based on another field, here is what I'm doing using JavaScript:

 

switch(con){

case 'Canada':

NWF$('#' + ciMyPeople).val('canada@mycompany.com');

break;

case 'US':

NWF$('#' + ciMyPeople).val('us@mycompany.com');

break;

}

the above code doesn't do anything.

Does anybody can help me please?

 

Thanks

Outcomes