我正在创建一个网站,为我们部门的每个人创建一个页面,上面有他们的联系信息。然后,可以从名片上的二维码链接到该页面。
从他们的SharePoint配置文件中获取信息的最佳方式是什么?
编辑:我对在Visual Studio中创建东西不是很熟悉。我在网站上使用Ruby on Rails,我读到SharePoint有REST服务,这将会很好用,但我似乎不知道如何访问用户档案信息。
发布于 2011-08-01 23:35:15
您不需要使用Visual Studio。您只需要能够使用来自Ruby的基于SOAP的web服务。User Profile web服务的文档位于此处:http://msdn.microsoft.com/en-us/library/aa980957(office.12).aspx
发布于 2011-08-01 22:45:56
您可以使用SharePoint UserProfile WebService来实现此目的。
http://msdn.microsoft.com/en-us/library/ms494053.aspx
或者,如果您需要更具体的东西,您可以创建自己的访问UserProfile WebService的API,如下所示-
using (var site = new SPSite("http://yourserver"))
{
var userProfileManager =
new UserProfileManager(SPServiceContext.GetContext(site));
var userProfile =
userProfileManager.GetUserProfile("domain\accountName");
//iterate the userprofile properties
foreach (UserProfileValueCollection prop in userProfile)
Console.WriteLine(prop.Value);
}https://stackoverflow.com/questions/6899534
复制相似问题