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
»
Resources
»
Whenever you get User Instance Disabled error follow these steps
ASP.NET
ADO.NET
Web Services
Remoting
Visual Studio 2005
Error Bank
Interview Questions
Tips & Tricks
XML
HTML
Jscript/Javascript
IIS
Windows
General
Submit Resource or code snippet
... and get
surprise gifts
Win Digital camera, ASP.NET Books, Free softwares!!
Whenever you get User Instance Disabled error follow these steps
07 Jul, 2008
Author:
Aashish
Summary
User Instance not allowed or disable use sp_configure to enable user instance.
.NET Classes used :
Here in aspspider and many other hosting sites user instances are disabled they only run a single instance of sql server and provide rights to your databse in that default instance.
They provide their default connection string which looks like this.
add name="ASPNETDBConnectionString" connectionString="Data Source=.\SQLExpress;Persist Security Info=True;Integrated Security=SSPI;Initial Catalog=yourloginname_ASPNETDB"
This is the change which you have to make to your default connection string in the web.config file
which looks like this.
add name="ASPNETDBConnectionString" connectionString="Data Source=.\SQLEXPRESS;AttachDbFilename=|DataDirectory|\ASPNETDB.MDF;Integrated Security=True;User Instance=True" providerName="System.Data.SqlClient"
Here user instance = "True" but here in aspspider and many other they do not allow this user instance.
But still after changing the connection string if you still receive the same error than you should try this piece of code.
remove name="LocalSqlServer"
add name="LocalSqlServer" connectionString="Data Source=.\SQLExpress;Persist Security Info=True;Integrated Security=SSPI;Initial Catalog=yourprovidedname_ASPNETDB"
And if you have more than one database to attach than you can similarly attach that and change only name and initial catalog part of the connection string.
remove name="LocalSqlServer1"
add name="LocalSqlServer1" connectionString="Data Source=.\SQLExpress;Persist Security Info=True;Integrated Security=SSPI;Initial Catalog=yourprovidedname_yourdatabasename"
This will definately remove this error.
Also remember you might have use conncetionstring or defined it in your code behind files on some of your pages also change connectionstring on those pages to the one given by the hosting provider or else those pages will again generate the same error.
Feedbacks about this page from members:
Thanks a lot
-
Mahesh Babu
I was trying to figure out what went wrong for many hours. 'To-the-point' article and it worked out.
I realized that many people face this problem here and I believe this article should go into the FAQ section of aspspider.
(05 Jan 2009)
Submit Feedback
View All Feedbacks
Total
members
:
250733
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.