System.ArgumentException: 项“user instance”的值无效
[ArgumentException: 项“user instance”的值无效。]
System.Data.Common.DbConnectionOptions.ConvertValueToBooleanInternal(String keyName, String stringValue) +1409631
System.Data.Common.DbConnectionOptions.ConvertValueToBoolean(String keyName, Boolean defaultValue) +56
System.Data.SqlClient.SqlConnectionString..ctor(String connectionString) +353
System.Data.SqlClient.SqlConnectionFactory.CreateConnectionOptions(String connectionString, DbConnectionOptions previous) +24
System.Data.ProviderBase.DbConnectionFactory.GetConnectionPoolGroup(String connectionString, DbConnectionPoolGroupOptions poolOptions, DbConnectionOptions& userConnectionOptions) +125
System.Data.SqlClient.SqlConnection.ConnectionString_Set(String value) +56
System.Data.SqlClient.SqlConnection.set_ConnectionString(String value) +4
System.Data.SqlClient.SqlConnection..ctor(String connectionString) +21
SqlHelp.GetList(String strQuery) in f:\dd\DragDropNews_51aspx\App_Code\SqlHelp.cs:71
_Default.Page_Load(Object sender, EventArgs e) in f:\dd\DragDropNews_51aspx\Default.aspx.cs:20
System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e) +15
System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +34
System.Web.UI.Control.OnLoad(EventArgs e) +99
System.Web.UI.Control.LoadRecursive() +47
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1061
public SqlHelp() {
string dbName = ConfigurationManager.AppSettings["sqlServer2005DbName"];
connString = @"Data Source=.\SQLEXPRESS;AttachDbFilename=" + HttpContext.Current.Request.PhysicalApplicationPath+dbName + ";Integrated Security=True;User Instance=True";
}
public SqlHelp(string connString) {
this.connString = connString;
}
--------------------编程问答-------------------- 在MSDN上收索"ArgumentException"实参和形参问题
补充:.NET技术 , C#