2014-09-22 83 views
0

'/ Court Case'应用程序中的服务器错误。

关键字不支持:'userid'。在我的网站中打开页面时出现错误

描述:执行当前Web请求期间发生未处理的异常。请查看堆栈跟踪以获取有关该错误的更多信息以及源代码的位置。

异常详细信息: System.ArgumentException:不支持的关键字:'userid'。

源错误:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below. 

堆栈跟踪:

[ArgumentException: Keyword not supported: 'userid'.] 
    System.Data.Common.DbConnectionOptions.ParseInternal(Hashtable parsetable, String connectionString, Boolean buildChain, Hashtable synonyms, Boolean firstKey) +6363422 
    System.Data.Common.DbConnectionOptions..ctor(String connectionString, Hashtable synonyms, Boolean useOdbcRules) +122 
    System.Data.SqlClient.SqlConnectionString..ctor(String connectionString) +113 
    System.Data.SqlClient.SqlConnectionFactory.CreateConnectionOptions(String connectionString, DbConnectionOptions previous) +35 
    System.Data.ProviderBase.DbConnectionFactory.GetConnectionPoolGroup(String connectionString, DbConnectionPoolGroupOptions poolOptions, DbConnectionOptions& userConnectionOptions) +221 
    System.Data.SqlClient.SqlConnection.ConnectionString_Set(String value) +64 
    System.Web.UI.WebControls.SqlDataSource.CreateConnection(String connectionString) +44 
    System.Web.UI.WebControls.SqlDataSourceView.ExecuteSelect(DataSourceSelectArguments arguments) +150 
    System.Web.UI.DataSourceView.Select(DataSourceSelectArguments arguments, DataSourceViewSelectCallback callback) +27 
    System.Web.UI.WebControls.DataBoundControl.PerformSelect() +261 
    System.Web.UI.WebControls.BaseDataBoundControl.EnsureDataBound() +82 
    System.Web.UI.WebControls.CompositeDataBoundControl.CreateChildControls() +95 
    System.Web.UI.Control.EnsureChildControls() +146 
    System.Web.UI.Control.PreRenderRecursiveInternal() +61 
    System.Web.UI.Control.PreRenderRecursiveInternal() +224 
    System.Web.UI.Control.PreRenderRecursiveInternal() +224 
    System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +3394 

版本信息: Microsoft .NET Framework版本:2.0.50727.8009; ASP.NET版本:2.0.50727.8010

回答

1

连接到数据库的连接字符串出现故障。它包含userid,而它应该是user id(之间有空格)。

查看connectionstrings.com的例子。

+0

感谢它的工作.. – 2014-09-22 06:12:02