|
SQL Server 不存在或访问被拒绝。
说明: 执行当前 Web 请求期间,出现未处理的异常。请检查堆栈跟踪信息,以了解有关该错误以及代码中导致错误的出处的详细信息。
异常详细信息: System.Data.SqlClient.SqlException: SQL Server 不存在或访问被拒绝。
源错误:
行 489: {
行 490: //打开数据库的连接
行 491: myConnection.Open();
行 492: }
行 493: catch(Exception ex)
源文件: G:\aspnet网络应用系统光盘\第9章\ExamineSystem\Include\UserDB.cs 行: 491
堆栈跟踪:
[SqlException: SQL Server 不存在或访问被拒绝。]
System.Data.SqlClient.ConnectionPool.GetConnection(Boolean& isInTransaction) +484
System.Data.SqlClient.SqlConnectionPoolManager.GetPooledConnection(SqlConnectionString options, Boolean& isInTransaction) +372
System.Data.SqlClient.SqlConnection.Open() +384
ExamineSystem.RoleDB.GetRoles() in G:\aspnet网络应用系统光盘\第9章\ExamineSystem\Include\UserDB.cs:491
[MyException: 数据库连接失败!]
ExamineSystem.RoleDB.GetRoles() in G:\aspnet网络应用系统光盘\第9章\ExamineSystem\Include\UserDB.cs:495
ExamineSystem.Default.BindRoleData() in G:\aspnet网络应用系统光盘\第9章\ExamineSystem\Default.aspx.cs:42
ExamineSystem.Default.Page_Load(Object sender, EventArgs e) in G:\aspnet网络应用系统光盘\第9章\ExamineSystem\Default.aspx.cs:35
System.Web.UI.Control.OnLoad(EventArgs e) +67
System.Web.UI.Control.LoadRecursive() +35
System.Web.UI.Page.ProcessRequestMain() +731 |