views:

366

answers:

1

I have a WSS 3.0 site with FBA and a custom user management web part. To track user email address, I have been using the Email property of the MembershipUser object. I just realized today that if you go into People and Groups and look at the email address for a user, the email address is blank, and can be edited there independent of the MembershipUser value. It seems that the alerts system uses the email address that is stored in People and Groups.

I have not gotten into recoding yet because I want to make sure I'm not missing anything first. I assume I could switch from MembershipUser.Email and story my information in SPUser.Email instead. But I seem to remember that on a different project I used MembershipUser.Email with no problems and the alerts went out fine (although that was MOSS).

So I guess I have two questions:

  1. Is there a way to tell People and Groups or the Alerts system to use MembershipUser.Email?
  2. Is it best practice to use SPUser.Email for email storage, rather than MembershipUser.Email?
+1  A: 

This post goes in-depth in getting SharePoint to sync the user profiles in your FBA store by naming all properties sharepoint should know about in the web.config and create those properties in your ProfileProvider. Not sure if it is what you are looking for exactly though. FBA user profile mapping does not work as clean as AD user profile mapping does out of the box.

Also, check out the User Profile Import Tool on CodePlex. It's for MOSS but might provide some pointers.

Colin
Thanks. Still not sure what the best practice is. I ended up changing it in MembershipUser and then in the SPUser object. I will take a look at this article, but I'm not sure if it deals with Email since that is not stored as a profile property in the membership database.
strongopinions