ASPNETDB.MDF, a database file, which is automatically created by .net framework when you created a ASP.NET web application by selecting ASP.NET Web Application not ASP.NET Empty Web Application (fig 1).
The new WebApplication1 came with its pre-created login and register page. You don't need any code for user registration and login process.
There will be no problem until you try to browse your website directly from web browser.
You will face this following error when you browse your website via web browser
"Login failed for user IIS APPPOOL\DefaultAppPool"
When you get this error, you can solve this by adding IUSR to your APP_Data folder's permission in your wwwroot or your website root folder.
You can also fix by transfer your tables and data from ASPNETDB.MDF to your application's sql database, and then you can change your connection string to point to new location of application services data tables.
But for the production site, there will be a different story.
You can find detail information about this issue at http://support.microsoft.com/?kbid=2002980.
It seems that I have to ask my hosting provider to add write permission on my application App_Data folder which is I am not comfortable to do.
No comments:
Post a Comment