SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I need to certain information. I read that it is not possible to get AD information unless you have some sort of solution that accesses it.

So the other option is the SharePoint user profiles.

How can I access it and get the information I want to display it... ie work phone, email, name... etc.

I need to create a directory.

share|improve this question
Hi mkhan, do you need to access user AD information from your SharePoint code or you want something else? – Zakir HC Mar 26 '13 at 7:02
What version of SharePoint do you use? Foundation? Server? – Andrew Adamich Mar 26 '13 at 7:46

If you want to fetch information form AD from your SharePoint Code/Solution, here is a reference you may be interested in: Get user data from AD

In the above given reference you can add your required data to be fetched, example:

string telephoneNumber = (string)currentUserProfile["telephoneNumber"].Value;
string mail = (string)currentUserProfile["mail"].Value;
string firstName = (string)currentUserProfile["givenName"].Value;

Check this you will get all AD property names: AD properties names

Hope this helps you.

share|improve this answer

You can use SPServices to achieve this but if you are looking to create a directory I would be tempted to customise a people search web part.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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