Hello, i have a list with user items and i would like to get the emailadress from the users listed in the list.Something likeweb.lists["My list"].items[0][Person].getEmail();Anyone who knows the correct syntax?
Hi,I guess some thing you can try in this way. If listhaving a column for user id.Then get user is using SPUser object and then you can get Email from SPUser Object.SPUser user = new SPUser (Listitem);user.Email --------------- will have email id.
Thank you for your answer.It is very probable your way will work.In the mean time i found another way that worked well for me.SPListItem listitem = properties.ListItem;String Email = null;SPFieldUser userFieldSalesManager = listitem.Fields["Created By"] as SPFieldUser;SPFieldUserValue userValueSalesManager =(SPFieldUserValue)userFieldSalesManager.GetFieldValue(listitem["Created By"].ToString());Email = userValueSalesManager.User.Email;