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 have a piece of code which gets the email address of a SPUser object. The email property is empty. Where I can fill the email address of this user? Is it in SharePoint or somewhere in AD? I dont have a sync connection to AD!

SPFieldUser userField = (SPFieldUser)currentItem.Fields.GetField(Constants.Fields.FIELD_CLIENT);
            SPFieldUserValue fieldValue = (SPFieldUserValue)userField.GetFieldValue(Convert.ToString(currentItem[Constants.Fields.FIELD_CLIENT]));
            SPUser assignedToUser = fieldValue.User;

string clientEmail = assignedToUser.Email;

// dosomething
share|improve this question

1.Assuming you do not have User Profiles Synchronized , there are no email address for the users You need to create a UserProfile Synchronization Service ,so that all the users are sync/imported to sharepoint. Later you can user profile code and get the relevant users information.


2.ELSE If you are not using/configuring User Profile Service anytime .You will need to have your design changed (where a user enters his/her email id) or some other mechanism.

share|improve this answer

You will need to actually request the user profile for that user so you can read all the properties for that user (including email). This question has some samples of how to do that in code: How to get user profile property value when privacy for property set to "Private" (only me)

share|improve this answer
Since there is no User Profile servive . How will this work ? – Nikhil Jangle Mar 21 '14 at 15:59

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.