Hi All,
I have to get all sharepoint user from specific Group in my ASP.NET Web Service. For that, I am using sharepoint web service :
i.e.http://<Site>/_vti_bin/usergroup.asmx
My Code is as follows:
CMS_Group_Service.UserGroup lstSharePointGroups = new CMS_Group_Service.UserGroup();
System.Net.NetworkCredential credentialSharePointWebService = new System.Net.NetworkCredential("UserName", "Password");
lstSharePointGroups.Credentials = credentialSharePointWebService;
System.Xml.XmlNode ndGroups = lstSharePointGroups.GetUserCollectionFromGroup("Formatter");
But above code is giving me an error:
"The request failed with HTTP status 401: Unauthorized."
but if I use other methods like "GetGroupCollectionFromSite", its work fine with me.
Please let me know. What I have to add to resolve this issue.