Quantcast
Viewing all articles
Browse latest Browse all 6517

New Post: Getting emply value from SPFindPeoplePicker

Hi Marc,

I am trying to get the people picker field (in my case ‘Forward To’) value using SPFindPeoplePicker in SharePoint 2013, but every time I am getting an empty value. And it showing empty dictionaryentries. Please find below my code, here before saving the list data I want to confirm the user if “Forward To” field is empty.

function PreSaveAction(){

var forwardTo = $().SPFindPeoplePicker({
peoplePickerDisplayName: “Forward To”,
checkNames: false
});
var forwardValue= forwardTo. currentValue;
If(forwardValue!=””){
return true;
}else{
var userResp=confirm(“Forward To is empty. Do you really want to Save It?”);
return userResp;
}
}

I am using jquery-1.10.2.min.js & jquery.SPServices-0.7.2.min.js but also tried with jquery-1.8.3.min.js but no luck. It will be really helpful if you can help me to figure out what I have missed. Thanks in advance.

//ahsan

Viewing all articles
Browse latest Browse all 6517

Trending Articles