Advertise with us
Control Panel
Forum
Hosting Help
ASP.NET 4.5 & SQL 2012 Hosting
Resources
Notice
Login
Members
Shared Hosting
|
Upgrade
|
Advertise
|
Tutorials
|
Home
»
Questions & Answers
»
I get hte error "Access denied creating App_Data subdirectory "
I get hte error "Access denied creating App_Data subdirectory "
24 Jan, 06
Author:
LINGLING CHEN
Fuelquip
Here is the detail of the error. What should I do?
Description: For security reasons, the identity 'NETWORK SERVICE' (under which this web application is running), does not have permissions to create the App_Data subdirectory within the application root directory. ASP.NET stores the Microsoft SQL Express Database file used for services such as Membership and Profile in the App_Data subdirectory of your application
Answers .............
Author:
Mike Low
Posted Date: 25 Jan, 06
Hi Lingling,
This may possibly help.
In your web.config, replace the line
<connectionStrings/>
with
<connectionStrings>
<remove name="LocalSqlServer"/>
<add name="LocalSqlServer" connectionString="Data Source=.\SQLExpress;Integrated Security=SSPI;Initial Catalog=jorya_aspnetdb"/>
</connectionStrings>
Hopefully, this will tell ASP.NET to use the aspnetdb.mdf in your database folder rather than app_data.
Good luck,
Mike.
Author:
LINGLING CHEN
Fuelquip
Posted Date: 25 Jan, 06
It works fine. Thank you very much mike. You are excellent.
Author:
Mike Low
Posted Date: 25 Jan, 06
I'm glad it is all working for you.
Have fun :)
Mike.
Author:
James van Scoyoc
CSUF
Posted Date: 01 Jun, 11
Mike's answer will help only if SQLEXPRESS is the server actually being used.
I got this error because I had started with a boilerplate basic MVC app from the wizard in Visual Studio 2010, but I wanted to use an existing SQL Server database for application data and authentication. I changed the auto-generated connection string to indicate my server rather than SQL Express, but I forgot to specify Integrated Security. Since my DB uses Windows authentication, this caused an error.
You must
login
to post answer for this question.
Total
members
:
250721
Average new registrations per day (in last 7 days):
7
New Registration:
Open
Register Now
Talk to Webmaster
Tony John
Facebook
Google+
Twitter
Advertise
Privacy Policy
Terms of use
Contact Us
SpiderWorks Technologies Pvt Ltd.
All Rights Reserved.