Solved

How do I create a Custom MembershipProvider?

Posted on 2006-11-05
3
252 Views
Last Modified: 2009-10-08
I have read postings all over the Internet including the one that was supposedly solved on your website titled "ASP.Net 2.0 - Adding extra information to the CreateUserWizard". Unfortuantely the link to the solution that was accepted no longer works and/or requires special access (it points to a Beta site).

I simply want to create a custom class that inherits from the SqlMembershipProvider class and override the CreateUser method so it accepts more arguments like FirstName, LastName, Address1, Address2, City, State, Zip, Phone etc.

I do not with to use the profile table at this stage. I have an existing database structure setup and I need to allow users to register for my site using my Custom provider, store the basic info in Microsoft's default aspnet_membership_user table and then execute another stored procedure that puts the remaining custom fields in my own table.

My problem is that I want to use pretty much all of the existing functionality that the SqlMembershipProvider has but just modify that one method (CreateUser). When I try to do that I get errors telling me that either some library is missing, protected or inaccessible due to security reasons (i.e. SecUtil class is declared internal) or a variety of other irritations. I don't know what to do. I managed to get the source code for the SQLMembershipProvider from Microsoft's website. It references a bunch of other libraries, two of which (SR and SecUtil) are giving me a really hard time b/c even though I have the source for them and try to include them in my project, it still seems like the compiler doesn't even know they are there!

Please help!

Thanks

UPDATE: I have actually made progress since posting this. I am now able to use my own provider (almost). I at least have the page calling my custom provider b/c I am getting an error when I try to create the new user and the error is found in my custom provider code but at least it's actually USING my custom provider.

The error is that it seems as though the Initialize method is not getting the connectionStringName passed in and therefore my exception handler is flagging it.
0
Comment
Question by:aschreiber2
3 Comments
 

Accepted Solution

by:
aschreiber2 earned 0 total points
ID: 17878497
Hooray for me!!!

I found the answer to my own question! Do I get points for it???

http://aspnet.4guysfromrolla.com/articles/070506-1.aspx
0
 
LVL 27

Expert Comment

by:Sammy
ID: 17878838
Go http://www.experts-exchange.com/Community_Support/ and ask for this question to be deleted and points refunded!
make sure you provide the link for the question http://www.experts-exchange.com/Programming/Programming_Languages/Dot_Net/ASP_DOT_NET/Q_22049798.html

0

Featured Post

VMware Disaster Recovery and Data Protection

In this expert guide, you’ll learn about the components of a Modern Data Center. You will use cases for the value-added capabilities of Veeam®, including combining backup and replication for VMware disaster recovery and using replication for data center migration.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

ASP.Net to Oracle Connectivity Recently I had to develop an ASP.NET application connecting to an Oracle database.As I am doing it first time ,I had to solve several problems. This article will help to such developers  to develop an ASP.NET client…
The article shows the basic steps of integrating an HTML theme template into an ASP.NET MVC project
This Micro Tutorial demonstrates using Microsoft Excel pivot tables, how to reverse engineer competitors' marketing strategies through backlinks.
Established in 1997, Technology Architects has become one of the most reputable technology solutions companies in the country. TA have been providing businesses with cost effective state-of-the-art solutions and unparalleled service that is designed…

809 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question