Geeks With Blogs
Chris Breisch   .NET Data Practices
Search this Blog!

Scott Guthrie points out a common gotcha when adding a customer provider in your web.config and an easy fix.

The <providers> section within the web.config file is implemented as a collection, and so it is possible to register multiple providers at the same time (this is useful when you want to have some users authenticated using one Membership store, and others authenticated using a separate Membership store).

By default ASP.NET 2.0 registers a set of default SQL Express providers within the root web.config file on your machine that create a SQL Express database within your /app_data directory to store/manage membership/role/profile data when you first access it.  Because this is registered at the machine-wide level, all provider collections by default inherit this registration.  Unless you explicitly <clear/> or override the inherited value, your application will have this default membership/role/profile provider registered.

Posted on Wednesday, November 22, 2006 7:00 AM .NET Development , ASP.NET | Back to top


Comments on this post: Tip-Of-The-Day: <clear/> When Adding Providers in ASP.NET

No comments posted yet.
Your comment:
 (will show your gravatar)


Copyright © Chris J. Breisch | Powered by: GeeksWithBlogs.net