ASP.NET树控件维护完美版 安装错误(数据库)

 

“/tree”应用程序中的服务器错误。

用户 'sa' 登录失败。

说明: 执行当前 Web 请求期间,出现未处理的异常。请检查堆栈跟踪信息,以了解有关该错误以及代码中导致错误的出处的详细信息。

异常详细信息: System.Data.SqlClient.SqlException: 用户 'sa' 登录失败。

源错误:

[没有相关的源行]

源文件: c:/WINDOWS/Microsoft.NET/Framework/v1.1.4322/Temporary ASP.NET Files/tree/3727f902/fe95af87/231dosl2.0.cs    行: 0

堆栈跟踪:

[SqlException: 用户 'sa' 登录失败。]
   System.Data.SqlClient.ConnectionPool.GetConnection(Boolean& isInTransaction) +484
   System.Data.SqlClient.SqlConnectionPoolManager.GetPooledConnection(SqlConnectionString options, Boolean& isInTransaction) +372
   System.Data.SqlClient.SqlConnection.Open() +384
   tree.config.Open() in D:/net/tree/config.cs:54
   tree.config..ctor() in D:/net/tree/config.cs:43
   tree.tree_Info..ctor() in D:/net/tree/tree_Info.aspx.cs:19
   ASP.tree_Info_aspx..ctor() in c:/WINDOWS/Microsoft.NET/Framework/v1.1.4322/Temporary ASP.NET Files/tree/3727f902/fe95af87/231dosl2.0.cs:0

[TargetInvocationException: 调用的目标发生了异常。]
   System.RuntimeType.CreateInstanceImpl(Boolean publicOnly) +0
   System.Activator.CreateInstance(Type type, Boolean nonPublic) +66
   System.Web.UI.TemplateControlParser.GetCompiledInstance(String virtualPath, String inputFile, HttpContext context) +164

[HttpException (0x80004005): 未能创建类型为“ASP.tree_Info_aspx”的页。]
   System.Web.UI.TemplateControlParser.GetCompiledInstance(String virtualPath, String inputFile, HttpContext context) +338
   System.Web.UI.PageParser.GetCompiledPageInstanceInternal(String virtualPath, String inputFile, HttpContext context) +43
   System.Web.UI.PageHandlerFactory.GetHandler(HttpContext context, String requestType, String url, String path) +44
   System.Web.HttpApplication.MapHttpHandler(HttpContext context, String requestType, String path, String pathTranslated, Boolean useAppConfig) +699
   System.Web.MapHandlerExecutionStep.System.Web.HttpApplication+IExecutionStep.Execute() +95
   System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +173



版本信息: Microsoft .NET Framework 版本:1.1.4322.573; ASP.NET 版本:1.1.4322.573

修改数据库的连接后又出现这个错误:

对象名 't_tree' 无效。

说明: 执行当前 Web 请求期间,出现未处理的异常。请检查堆栈跟踪信息,以了解有关该错误以及代码中导致错误的出处的详细信息。

异常详细信息: System.Data.SqlClient.SqlException: 对象名 't_tree' 无效。

源错误:

执行当前 Web 请求期间生成了未处理的异常。可以使用下面的异常堆栈跟踪信息确定有关异常原因和发生位置的信息。

堆栈跟踪:

[SqlException: 对象名 't_tree' 无效。]
   System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream) +723
   System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior behavior) +45
   System.Data.SqlClient.SqlCommand.System.Data.IDbCommand.ExecuteReader(CommandBehavior behavior) +5
   System.Data.Common.DbDataAdapter.FillFromCommand(Object data, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior) +304
   System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior) +77
   System.Data.Common.DbDataAdapter.Fill(DataSet dataSet) +38
   tree.config.Fill(String str_Sql) in D:/net/tree/config.cs:79
   tree.config.GetRowCount(String str_Sql) in D:/net/tree/config.cs:142
   tree.tree_Info.Page_Load(Object sender, EventArgs e) in D:/net/tree/tree_Info.aspx.cs:27
   System.Web.UI.Control.OnLoad(EventArgs e) +67
   System.Web.UI.Control.LoadRecursive() +35
   System.Web.UI.Page.ProcessRequestMain() +731

去企业管理器的tree数据库看了看,竟然没有表t_tree,汗,不过查询分析器里执行它本身带着的sql语句是成功的啊:

if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[t_tree]') and OBJECTPROPERTY(id, N'IsUserTable') = 1)
drop table [dbo].[t_tree]
GO

CREATE TABLE [dbo].[t_tree] (
 [nodeid] [int] NOT NULL ,
 [parentid] [nvarchar] (50) COLLATE Chinese_PRC_CI_AS NULL ,
 [mytext] [nvarchar] (100) COLLATE Chinese_PRC_CI_AS NULL ,
 [location] [nvarchar] (50) COLLATE Chinese_PRC_CI_AS NULL ,
 [order_id] [int] NULL
) ON [PRIMARY]
GO

ALTER TABLE [dbo].[t_tree] WITH NOCHECK ADD
 CONSTRAINT [PK_tree] PRIMARY KEY  CLUSTERED
 (
  [nodeid]
 )  ON [PRIMARY]
GO

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值