Custom Error messages in MembershipProvider
Posted on 2007-11-16
I have created a custom MembershipProvider, and in the code there, is there a way to override the messages that display in the controls for log in and registration....
For instance, in the CreateUser() Function, instead of sending back the DuplicateEmail message, I need to send a custom message as shown in the comment below. Is that possible to override these "red" messages that are displayed?
If RequiresUniqueEmail AndAlso GetUserNameByEmail(email) <> "" Then
'status = "You already have an account. Request a forgot login reminder."
status = MembershipCreateStatus.DuplicateEmail