ご存知かもしれませんが、MOSS 2007 には、Active Directory プロパティを SharePoint UserProfile プロパティに同期する機能があります。[Shared Services] > [User Profile and Properties] > [View Profile properties] (一番下) で、AD プロパティを userProfile プロパティにマップできます。
現在、userProfiles の変更を AD に同期する可能性を調査しています。
私は SharePoint を初めて使用し、その API を使用するのに苦労していますが、これまでに掘り下げたのは、UserProfile の変更を反復処理して、タイムスタンプ、古い値、新しい値などを見つけることができるということです.
string siteUrl = @"http://[siteUrl]/";
Microsoft.SharePoint.SPSite spsite = new Microsoft.SharePoint.SPSite(url);
Microsoft.Office.Server.ServerContext serverContext = Microsoft.Office.Server.ServerContext.GetContext(spsite);
Microsoft.Office.Server.UserProfiles.UserProfileManager userProfileMgr = new Microsoft.Office.Server.UserProfiles.UserProfileManager(serverContext);
var collection = userProfileMgr.GetChanges();
List<ProfilePropertyChange> changes = new List<ProfilePropertyChange>();
foreach (Microsoft.Office.Server.UserProfiles.UserProfileChange change in collection)
{
if (change.ObjectType == Microsoft.Office.Server.UserProfiles.ObjectTypes.SingleValueProperty)
{
var singleValue = change as Microsoft.Office.Server.UserProfiles.UserProfileSingleValueChange;
string oldValue = singleValue.OldValue;
string newValue = singleValue.NewValue;
var profileProperty = singleValue.ProfileProperty;
DateTime modificationDate = singleValue.EventTime;
...
}
}
ただし、現在発見できないのは、いわゆる「マップされた属性」(AD の元のプロパティ名) へのプログラムによるアクセスです。
この情報を明らかにしてくれる SharePoint API を教えてくれる人はいますか?
どうもありがとう