Customer Membership/Role provider problem



I downloaded the source code for the membership classes that are used for
Security in .Net 2.0 and I am having an issue using a custom provider I
created.
I needed to overload the "CreateRole" method so I could insert a description
of the role, so I created a 2nd "CreateRole" method to handle this. There
are other changes I need to do, but I wanted to start with this simple one
to see how this would work.


In the downloaded code, I changed the namespace, renamed the project and
created a DLL called CF.MembershipCustom.dll and referenced that in my UI
project. I updated the config file to use this new dll. Here is the
updated code (see below)...

Everything compiled nice, but now in the UI layer, I expected I could do
this...

Roles.CreateRole("name of role", "description of role");

BUT, there is no overloaded method!

I CAN do this...
RoleCustomProvider roleCustomProvider = new RoleCustomProvider();
roleCustomProvider.CreateRole("name of role", "description of role");



I thought the whole point of the provides was that I could customize what I
needed changed,but still use the same Method calls? I'm assuming I
ammissing a critical step and I appreciate anyone's help.

Thanks in advance!

Brian


<system.web>



<roleManager enabled="true" defaultProvider="RoleCustomProvider">


<providers>

<clear/>

<add name="RoleCustomProvider"

type="CF.MembershipCustom.RoleCustomProvider, CF.MembershipCustom"

connectionStringName="CAAP"

applicationName="ApplicationCenter"/>

</providers>

</roleManager>



<membership defaultProvider="MembershipCustomProvider">

<providers>

<clear/>

<add name="MembershipCustomProvider"

type="CF.MembershipCustom.MembershipCustomProvider, CF.MembershipCustom"

connectionStringName="CAAP"

enablePasswordRetrieval="false"

enablePasswordReset="true"

requiresQuestionAndAnswer="false"

applicationName="ApplicationCenter"

requiresUniqueEmail="false"

passwordFormat="Hashed"

maxInvalidPasswordAttempts="5"

minRequiredPasswordLength="1"

minRequiredNonalphanumericCharacters="0"

passwordAttemptWindow="10"

passwordStrengthRegularExpression="" />

</providers>

</membership>



</system.web>





.



Relevant Pages

  • How to use MS Access DB for ASPNET Application Services (membership, profile, etc)
    ... web hostings for ASPNET 2.0 will offer only MS Access ... Change the name of DLL. ... with "ASP.NET Access Providers" ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: How to Remote a custom membership or profile provider ???
    ... If your type is NOT in the APP_CODE folder (you define it in a separate Class Library DLL project), you need to specify the assembly within the type attribute (in the form "typename, assemblyname"). ... The example above assumes you added a referece to your DLL from your web project, so the MyRemotableProviders.dll binary is in the website's bin folder. ...
    (microsoft.public.dotnet.framework.aspnet)