Page 1 of 1
set People Picker with multiple reada from two people pickers
Posted: 13 Apr 2017
by surya250
hi need to read two people pickers and set people picker with allow multiple
Re: set People Picker with multiple reada from two people pickers
Posted: 13 Apr 2017
by Dmitry Kozlov
Hi,
Here are code samples:
Code: Select all
//setting multiple values:
fd.field('User').value('Dmitry; Anna');
// getting the second value:
fd.field('User').value()[1]
Re: set People Picker with multiple reada from two people pickers
Posted: 17 Apr 2017
by surya250
else if ((fd.field('Work_x0020_Stage').value() == '3. Have discussion meeting') || (fd.field('Work_x0020_Stage').value() == '4. Owners Decide'))
{
var standardOwner1= null;
var standardOwner2= null;
fd.field('Standard_x0020_Owner_x0020_1').control('ready', function()
{
var selectedUsers = fd.field('Standard_x0020_Owner_x0020_1').value();
if(selectedUsers != null)
{
for (var i = 0; i < selectedUsers.length; i++)
{
//alert('Login: ' + selectedUsers.Description);
//alert('3,4 Field changed!');
standardOwner1 = fd.field('Standard_x0020_Owner_x0020_1').value()[0]['Description'];
//alert('Login: ' + standardOwner1);
//fd.field('AssignedTo').value(fd.field('Standard_x0020_Owner_x0020_1').value()[0]['Description']);
}
}
});
fd.field('Standard_x0020_Owner_x0020_2').control('ready', function()
{
var selectedUsers = fd.field('Standard_x0020_Owner_x0020_2').value();
if(selectedUsers != null)
{
for (var i = 0; i < selectedUsers.length; i++)
{
standardOwner2= fd.field('Standard_x0020_Owner_x0020_2').value()[0]['Description'];
alert('Login: ' + standardOwner2);
alert('Login: ' + standardOwner1);
//fd.field('AssignedTo').value();
//alert('Login: ' + selectedUsers.Description);
//fd.field('AssignedTo').value(fd.field('Standard_x0020_Owner_x0020_2').value()[0]['Description']);
//alert('3,4 Field changed!');
}
}
});
}
I need set Assigned TO value 'Standard_x0020_Owner_x0020_1' and 'Standard_x0020_Owner_x0020_2' bought the values its multiple allow people picker .
Re: set People Picker with multiple reada from two people pickers
Posted: 17 Apr 2017
by Dmitry Kozlov
Hi,
Please, send the detailed description of your requirements with screenshots of your form to
support@spform.com and we will estimate them.
As for populating a User field with the support of multiple values, the code below works fine:
Code: Select all
fd.field('User').value('user1@gmail.com; user2@gmail.com');
Replace 'User' with the internal name of your User or Group column.