| 网站首页 | 业界新闻 | 小组 | 威客 | 人才 | 下载频道 | 博客 | 代码贴 | 在线编程 | 编程论坛
欢迎加入我们,一同切磋技术
用户名:   
 
密 码:  
共有 549 人关注过本帖
标题:不支持关键字: “attachdbfile name”。
只看楼主 加入收藏
jinxiaoyan
Rank: 1
等 级:新手上路
帖 子:1
专家分:0
注 册:2012-12-23
收藏
 问题点数:0 回复次数:0 
不支持关键字: “attachdbfile name”。
不支持关键字: “attachdbfile name”。
说明: 执行当前 Web 请求期间,出现未处理的异常。请检查堆栈跟踪信息,以了解有关该错误以及代码中导致错误的出处的详细信息。

异常详细信息: System.ArgumentException: 不支持关键字: “attachdbfile name”。

源错误:


行 32:         }
行 33:         string ConnSql = ConfigurationManager.ConnectionStrings["ConnString"].ToString();
行 34:         SqlConnection Conn = new SqlConnection(ConnSql);
行 35:         Conn.Open();
行 36:         string StrinSQL = "select * from users where userid='" + txtid.Text + "' and userpwd='" + txtpassword.Text + "'";
 

源文件: c:\Users\delll\Desktop\新建文件夹 (3)\用户登录.aspx.cs    行: 34

堆栈跟踪:


[ArgumentException: 不支持关键字: “attachdbfile name”。]
   System.(Hashtable parsetable, String connectionString, Boolean buildChain, Hashtable synonyms, Boolean firstKey) +4909748
   System.(String connectionString, Hashtable synonyms, Boolean useOdbcRules) +98
   System.Data.SqlClient.SqlConnectionString..ctor(String connectionString) +55
   System.Data.SqlClient.SqlConnectionFactory.CreateConnectionOptions(String connectionString, DbConnectionOptions previous) +24
   System.Data.ProviderBase.DbConnectionFactory.GetConnectionPoolGroup(String connectionString, DbConnectionPoolGroupOptions poolOptions, DbConnectionOptions& userConnectionOptions) +200
   System.Data.SqlClient.SqlConnection.ConnectionString_Set(String value) +62
   System.Data.SqlClient.SqlConnection.set_ConnectionString(String value) +4
   System.Data.SqlClient.SqlConnection..ctor(String connectionString) +24
   Default2.Unnamed1_Click(Object sender, EventArgs e) in c:\Users\delll\Desktop\新建文件夹 (3)\用户登录.aspx.cs:34
   System.Web.UI.WebControls.Button.OnClick(EventArgs e) +111
   System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument) +110
   System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) +10
   System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +13
   System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +36
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1565

 

搜索更多相关主题的帖子: 详细信息 关键字 
2012-12-23 10:10
快速回复:不支持关键字: “attachdbfile name”。
数据加载中...
 
   



关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 0.025153 second(s), 8 queries.
Copyright©2004-2024, BCCN.NET, All Rights Reserved