473,407 Members | 2,320 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,407 software developers and data experts.

2.0: error opening ASPNETDB

RAM
Hello,
I have written simple ASP.NET application with logging in. I need to
open ASPNETDB database to read some information which is not available
using class library (custom table).
I have written:

using (SqlConnection aspnetdb = new
SqlConnection(ConfigurationManager.ConnectionStrin gs["ASPNETDB"].ConnectionString))
{
aspnetdb.Open(); // here problem
...
}
In web.config I have:
<add name="ASPNETDB" connectionString="Data
Source=localhost;Initial catalog=MIMMagazynASPNETDB;Integrated
Security=True;User Instance=True"/>

The problem occurs on opening ASPNETDB:
aspnetdb.ServerVersion...Message is "Invalid operation. The connection
is closed."
aspnetdb.ServerVersion...StackTrace is
" at System.Data.SqlClient.SqlConnection.GetOpenConnect ion()\r\n
at System.Data.SqlClient.SqlConnection.get_ServerVers ion()"

Please help.
/RAM/

PS. I really need to open ASPNETDB.
Jul 20 '06 #1
0 1168

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Bendik Engebretsen | last post by:
I have made an ASP.NET 2.0 WebSite using the 'Personal WEB site' starter kit. It runs fine on my XP machine where I have the VStudio.NET 2005 Beta installed. But if I try to run it from our Win...
2
by: keithb | last post by:
This is on a remote server. Everything works in the development envirmonment. Any ideas? Thanks, Keith Failed to update database "C:\BTM_ROOT\APP_DATA\ASPNETDB.MDF" because the database is...
2
by: JoeFusion | last post by:
Hi folks, I am trying to use the new User Profile functionality in ASP.Net 2, and on initial impression, it looked simple enough to use. But I seem to be getting in a bit of a mess as to what...
1
by: 3Dfelix | last post by:
Problems when uploading ASPNETDB.MDF to production server Hi all, I'm a little web with a login page and aspnetdb.mdf file as data base for users. I've done it on local server, with VS2005 and...
1
by: CFTK | last post by:
This is the error I get when I try to login in my application from another machine: An attempt to attach an auto-named database for file C:\Documents and Settings\....\App_Data\aspnetdb.mdf...
3
by: GaryDean | last post by:
I noticed that my asp.net project contains a 10 meg ASPNETDB.MDF database in the App_data folder. I never intentionally put it there, have never ran regsql.exe. Reading back on my logs it got...
4
by: jobs | last post by:
Works great on my client when I test from vs.net 2005. Howevever, when I deploy to the web server, I get this error: remotely and local from the web server. An error has occurred while...
0
by: jobs | last post by:
I renamed the name of my remote database where I had a working AspNetdb configuration working. I now get this error when I compile in development: An error occurred during the execution of the...
13
by: AAaron123 | last post by:
I downloaded the personal website starter kit and when I run it I get the error shown below. I found a way of using Launch Surface Area Configuration that is supposed to fix the remote setting...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.