CodeVerge.Net Beta


   Explore    Item Entry    Members      Register  Login  
NEWSGROUP
.NET
Algorithms-Data Structures
Asp.Net
C Plus Plus
CSharp
Database
HTML
Javascript
Linq
Other
Regular Expressions
VB.Net
XML

Free Download:




Zone: > NEWSGROUP > Asp.Net Forum > visual_studio.vs_2005_web_application_projects Tags:
Item Type: NewsGroup Date Entered: 10/4/2006 3:25:02 PM Date Modified: Subscribers: 0 Subscribe Alert
Rate It:
(NR, 0)
XPoints: N/A Replies: 4 Views: 17 Favorited: 0 Favorite
Can Reply:  No Members Can Edit: No Online: Yes
5 Items, 1 Pages 1 |< << Go >> >|
poulterhd
Asp.Net User
Costom Role Provider does not work in web app project.10/4/2006 3:25:02 PM

0/0

 

I am having trouble using my custom role provider with a web application so I created two minimal projects - one as a web site and the other as a web application project.  They are as alike as I can make them, consisting of  a default.aspx page, a login.aspx page, a web reference to a web service I  am using for authentication/authorization, and my two custom classes, CustomMembershipProvider.vb and CustomRoleProvider.vb

The web site version works fine (in that it redirects to login.aspx).  The web application project version can't load the roles provider.  I get a yellow screen with:

Parser Error Message: Could not load type 'CustomRoleProvider'.

 The web.config files are identical in the authorization, authentication, membership and roleManager sections; the code in the CustomRoleProvider claass is exaclty the same.  I don't have any trouble dimming something as an instance of CustomRoleProvider in code.

Does the web application project require a different schema here? What the hey is going on?

<authorization>

<deny users="?"/>

<allow roles="AUTHUSERS"/>

<deny users="*"/>

</authorization>

<authentication mode="Forms">

<forms name="SecurityCookie" loginUrl="~/Login.aspx" protection="All" timeout="180">

</forms>

</authentication>

<membership defaultProvider="CustomMembershipProvider">

<providers>

<add name="CustomMembershipProvider" type="CustomMembershipProvider" requiresQuestionAndAnswer="false"/>

</providers>

</membership>

<roleManager enabled="true" defaultProvider="CustomRoleProvider" cacheRolesInCookie="true">

<providers>

<add name="CustomRoleProvider" type="CustomRoleProvider"/>

</providers>

</roleManager>

 

 

 

 



 

 

 

Nordite
Asp.Net User
Re: Costom Role Provider does not work in web app project.10/18/2006 1:23:55 AM

0/0

Did you find any answer to this?  I have a similar problem and was wondering if you found any solution.  I am running SQL Personal server 2000.  I am just going through a tutorial on my local PC using a local SQL personal server instance.  I can do everything but connect to the provider in my ASP.NET 2.0 Administration Tool. 

Thanks

Nordite

sontek
Asp.Net User
Re: Costom Role Provider does not work in web app project.10/19/2006 7:17:17 AM

0/0

It will work if you fully qualify the class name with its namespace first.   Like   WebsiteTestWAP.CustomMembershipProvider

Sontek Blog: http://blog.sontek.net
poulterhd
Asp.Net User
Re: Custom Role Provider does not work in web app project.10/19/2006 12:13:37 PM

0/0

Thanks - I'll try that next time.  Since I had to deliver the app, I went back to a website-based conversion.  It is odd that it apparently recognized the membership provider class with no namespace qualifier, but choked on the role provider class.

 

zuperman
Asp.Net User
Re: Custom Role Provider does not work in web app project.2/9/2007 1:42:36 PM

0/0

You have to programatically recreate the roles again: something like this:

Roles

.CreateRole("rolename");

Something to do with the Application ID that has changed on the new environment.

After you add the roles to your database it will work perfectly.


http://www.aello.ro
http://zuperman.aello.ro
5 Items, 1 Pages 1 |< << Go >> >|


Free Download:

Books:
MCAD Developing and Implementing Web Applications with Microsoft Visual C#(TM) . NET and Microsoft Visual Studio(R) . NET Exam Cram 2 (Exam Cram 70-315): Exam Cram 2, McAd Exam 70-315 Authors: Kirk Hausman, Amit Kalani, Ed Tittel, Pages: 600, Published: 2003
Pro ASP.NET for SQL Server: High Performance Data Access for Web Developers Authors: Brennan Stehling, Pages: 408, Published: 2007
Systems Analysis and Design: An Applied Approach Authors: Alan Dennis, Barbara Haley Wixom, Pages: 516, Published: 2000
Learning WCF: Master Windows Communication Foundation and Soa Fundamentals Authors: Michele Leroux Bustamante, Pages: 582, Published: 2007
Professional DotNetNuke 4: Open Source Web Application Framework for ASP.NET 2.0 Authors: Shaun Walker, Joe Brinkman, Bruce Hopkins, Scott McCulloch, Patrick J. Santry, Chris Paterra, Scott Willhite, Dan Caron, Pages: 517, Published: 2006

Web:
Costom Role Provider does not work in web app project. - ASP.NET ... Costom Role Provider does not work in web app project. Last post 02-09-2007 8:42 AM by zuperman. 4 replies. Sort Posts: ...
CodeProject: Custom MembershipProvider and RoleProvider ... Custom MembershipProvider and RoleProvider implementations that use web ... via a web service and thus require that our application does not require direct ...
MSDN Common Language Runtime Encrypted appSettings section not ... Encrypted appSettings section not recognized by custom role provider class. ... project on my local machine and ran the web app with debugger (F5) and had a ...
Custom roleprovider caching. - ng.asp-net-forum.security - Fix ... NET " Security " WebAdmin Tool not fully using custom RoleProvider ... cache caching, configuration tool roles membership, web site administration tool . ...
Forms Authentication in SharePoint Products and Technologies (Part ... Web.Security.RoleProvider; if you are writing a custom role provider you must ...... In most cases, the Visual Studio Add Web Reference wizard does not work ...
Re: Supporting multiple custom RoleProvider versions NET 2.0 does support multiple providers configured in appilcation web.config file. And you can point to the RoleProvider type in both GAC or application's ...
Software/Technology Discussion : Custom Membership Provider under ... Open a new browser window using the URL for the custom web application. ..... The reason your code does not work on Windows 2003 but does on XP could be all ...
CodeProject: RoleProvider for web applications that use XML files ... Oct 16, 2006 ... Well I understand now, the problem is not the RoleProvider, ... So I modified it to make it work on SQL 2005, and now my project is working ...
Active Directory Role Provider « where coding happens ! Feb 14, 2008 ... Web.Security.RoleProvider in order to use it as your application .... Also, you might be interested in a similar project I’ve been working ...
Problems With Custom RoleProvider and Forms Authentication - .NET ASP For any reason, AcquireRequestState does not fire after ... on how your custom membership/role provider will rely on those stateful ...




Search This Site:










small coremod for 3.0.10 in order to change locale for anonymous user

problem using inline for loop

guid

dropdownlist

users, profiles and their data

how to hide/mask url

bypass validation

edit module definitions error

compiling dll's

converting code to c#

using the entire pane

page with menu does not validate

manually create child portal

incorrect syntax - error

sharing information between asp.net n' classic asp

just email the order

where's code for changing default page on login?

create a global function

can i use the value in a querystring in the page title?

new c# task manager module

how to create a custom event when a security role assigned to user

how to launch .exe file that uses command line in asp?

templates - how

assembly version and database

how to fire off an insert sql statement to access from an aspx page

sql server error

form authentication for only 1 page in a web site of 5 pages.

i can't download the web controls

is it possible to create a web project (file system) in root in vs2005?

calling functions in links

 
All Times Are GMT