Solved

How do I create a Custom MembershipProvider?

Posted on 2006-11-05
3
254 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

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
performance issue in asp web 5 37
imap read mail 1 34
Setting up a IIS 8 Web Server to send and receive XML files 7 35
ASP.NET Content Page 3 25
I have developed many web applications with asp & asp.net and to add and use a dropdownlist was always a very simple task, but with the new asp.net, setting the value is a bit tricky and its not similar to the old traditional method. So in this a…
It was really hard time for me to get the understanding of Delegates in C#. I went through many websites and articles but I found them very clumsy. After going through those sites, I noted down the points in a easy way so here I am sharing that unde…
Nobody understands Phishing better than an anti-spam company. That’s why we are providing Phishing Awareness Training to our customers. According to a report by Verizon, only 3% of targeted users report malicious emails to management. With compan…
I've attached the XLSM Excel spreadsheet I used in the video and also text files containing the macros used below. https://filedb.experts-exchange.com/incoming/2017/03_w12/1151775/Permutations.txt https://filedb.experts-exchange.com/incoming/201…

840 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