I am trying to retrieve a user's email address in SF 4.1 and am having some problems. I used the code below in SF 4.0 and it worked fine, but now I get a squiggly under the 'user.Email' with this Warning:
'Public Overrides Property Email As String' is obsolete: 'This is now persisted as part of the user profile.'.
Can someone tell me how to correct the issue?
userMan = UserManager.GetManager()
user = userMan.GetUser(SecurityManager.GetCurrentUserName)
email.Text = user.Email