In a web part (either out of the box or custom), I would like to list the user profiles most recently imported from Active Directory. This would be roughly equivalent to the most recent hires. Is this possible, and if so, what is the best approach?

1 Answer 1


Considering the fact that there could be lots of users in Active Directory, I reckon that the best approach here will be to use SharePoint search, sort by Hire date descending, and select only top N users. Then, you can display results, for example using DataViewWebPart.

It is not an easy way to achieve the goal, but it is preferrable. Here are some links which can help you with this:

Easier solution could be implemented, if you're sure that the number of users in your Active Directory will always remain small (less than 200 users, for example). In this case you can simply create a custom webpart, grab all the User Profiles using UserProfileManager class, and sort them by the "Hire date" property with help of Linq-to-object. Finally, you can display this information using ASP.Net Repeater or DataView controls.

In either case, you have to configure the "Hire date" User Profile property and map it to the "createTimeStamp" Active Directory attribute.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.