This project has moved and is read-only. For the latest updates, please go here.

Updating a list Item including a User or Group Column

Feb 2, 2016 at 3:21 PM
Hi Marc,

Below is the code for the function I am using to update a list item. My list contains information about manager (ID, Name, email). When list item is created it can either have ID of manager or can be blank. If ID is there, Name and Email fields are filled automatically. What I am trying to do in this function is if Manager information is not in the list then user who is making a request is asked to update manager ID which I am storing in a variable and then passing to this function but my item is not updating.

function UpdateListItem(currentItemId, listName, column, idvalue)

var userManager = $().SPFindPeoplePicker({
                    peoplePickerDisplayName: column

userManager.currentValue = idvalue;
var listColumns;
listColumns = [[column,userManager.currentValue]];

    async: false,
    batchCmd: "Update",
    listName: listName,
    ID: currentItemId,
    valuepairs: listColumns,
    completefunc:function(xData, Status)


Feb 2, 2016 at 3:26 PM
Are you getting any errors in the response? Are you sure that userManager.currentValue is a userId?

Feb 2, 2016 at 3:31 PM
Yes Marc, I have debugged it and the alerts are showing userManager.currentValue is the value I am passing through variable (a UserID). I cannot see any error except when is used 'alert(xData.responseText)'

Feb 2, 2016 at 3:43 PM
You'll need to look at the request and the response in the debugging tools to see what the problem is. Does xData.responseText show you anything?