I came across this post showing how to create a permissions management webPart using SPServices. I tried to do it in SP2010 but keep getting error " User not found". I think it has something to do with the "userLoginName", I'm not sure how to alter it.

This is the part of the code causing the error:

  //Populate the Groups Assigned
      operation: "GetGroupCollectionFromUser",
      userLoginName: $("#my_SiteUsers").attr("value"),
      async: false,
      completefunc: function(xData, Status) {
        $(xData.responseXML).find("errorstring").each(function() {
          alert("User not found");
          booErr = "true";
        $(xData.responseXML).find("Group").each(function() {
          strHTMLAvailable += "<option value='" + $(this).attr("Name") + "'>" + $(this).attr("Name") + "</option>";
          arrOptionsAssigned[intOpts] = $(this).attr("Name");
          intOpts = intOpts + 1;
  • Can you post what the value ofvb$("#my_SiteUsers").attr("value")b looks like? It may be an escaping thing, depending on your auth method. It could also be due to your permissions. – Marc D Anderson Oct 11 '13 at 15:38
  • Hi Mark, this is an old question. I don't know why but I found that passing a variable as the userLoginName worked for me. Plus it makes reuse a bit easier. Thanks for the reply. – Batman Oct 11 '13 at 19:46

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.