Format of the initialization string does not conform to specification starting at index 5."
From: andy (adheyworth_at_gmail.com)
Date: 12/21/04
- Next message: Joe: "Re: Help with FindControl method"
- Previous message: Kenneth P: "Where's Microsoft.Web.UI.WebControls.dll?"
- Messages sorted by: [ date ] [ thread ]
Date: 21 Dec 2004 14:38:23 -0800
Hi all,
Any help much appreciated - Andy
I am trying to connect to a SQL Server DB using c#, ADO.Net
mySqlConnection = new
SqlConnection(@"user=ddd;password=jfn;server=srv5;Trusted_Connection=no;database=dan");
as you can see there are "special" ASCII chars in the user and password
fields. (ASCII 127 and ASCII 157). The following error results when
trying to connect, where index 5 is the '' char in the user name.
"Format of the initialization string does not conform to specification
starting at index 5."
StackTrace
at System.Data.Common.DBConnectionString.GetKeyValuePair(Char[]
connectionString, Int32 currentPosition, String& key, Char[] valuebuf,
Int32& vallength, Boolean& isempty)\r\n
at System.Data.Common.DBConnectionString.ParseInternal(Char[]
connectionString, UdlSupport checkForUdl, NameValuePair& keychain)\r\n
at System.Data.Common.DBConnectionString..ctor(String
connectionString, UdlSupport checkForUdl)\r\n
at System.Data.SqlClient.SqlConnectionString..ctor(String
connectionString)\r\n
at System.Data.SqlClient.SqlConnectionString.ParseString(String
connectionString)\r\n
at System.Data.SqlClient.SqlConnection.set_ConnectionString(String
value)\r\n
at System.Data.SqlClient.SqlConnection..ctor(String
connectionString)\r\n
at HowTo.Samples.ADONET.sqldtreader.Run()
- Next message: Joe: "Re: Help with FindControl method"
- Previous message: Kenneth P: "Where's Microsoft.Web.UI.WebControls.dll?"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|