ConnectionString using DSN not working
- From: Fendi Baba <effendi@xxxxxxxxxxxxxx>
- Date: 17 Apr 2007 04:32:57 -0700
I have been using SqlConnection .NET strings in my web,config and my
application is working finr. However due to requirements, I am forced
to change the connection string to use DSN and I cannot connect to the
data. Can anyone point out what is wrong with my settings.
Here is the SqlConnection in my web.config
<add name="LocalSqlServer" connectionString="server=EFFENDI
\SQLEXPRESS;uid=CoopAdmin;pwd=pass;database=coopgown"
providerName="System.Data.SqlClient" />
And here is the one using DSN
<add name="LocalSqlServer"
connectionString="Dsn=DBADGRAD;uid=CoopAdmin;pwd=pass"
providerName="System.Data.Odbc" />
When I try to open the Asp.net application Configuration pages, I get
the following error mesages
An error occurred while attempting to initialize a
System.Data.SqlClient.SqlConnection object. The value that was
provided for the connection string may be wrong, or it may contain an
invalid syntax. Parameter name: connectionString
Any ideas?
Thanks in advance.
.
- Follow-Ups:
- Re: ConnectionString using DSN not working
- From: Mary Chipman [MSFT]
- Re: ConnectionString using DSN not working
- From: Norman Yuan
- Re: ConnectionString using DSN not working
- Prev by Date: Re: Is it just me or have adapters taken a MASSIVE step forward in 2.0?
- Next by Date: Re: Writing a Decimal to SqlServer loses the fraction
- Previous by thread: Problem in inserting data into AccessDB
- Next by thread: Re: ConnectionString using DSN not working
- Index(es):
Relevant Pages
|