sharekasce.blogg.se

Sql server connection string web config
Sql server connection string web config







sql server connection string web config
  1. #SQL SERVER CONNECTION STRING WEB CONFIG FULL#
  2. #SQL SERVER CONNECTION STRING WEB CONFIG CODE#

Rather than using an ODCB connection, use just a direct connection to the access database (). Please help me i am upset with it, i am good at ASP and C# coding but the above problem of deploying the ASP web with access database is making me frustrated Will the above situation needs some changes in web.config? if after making access db on server my server gives an ODBC connection string ,then where should i deploy this ODBC thing ? If i upload a folder name "testweb" which has by default configurations of "web.config" and in that i have a simple page "abc.aspx" then have gridview name "grid" bounded with access db naming "db.mdf" via acccess datasource name "src" "Or you can reference this declaratively within the ConnectionString property of a SqlDataSource"Īre you sure? I get the error: The AccessDataSource ConnectionString property cannot be set, it is automatically generated. Or you can reference this declaratively within the ConnectionString property of a SqlDataSource:

#SQL SERVER CONNECTION STRING WEB CONFIG FULL#

Note that the namespace for this is System.Configuration so for a console application the full namespace is required. String connStr = ĭim connStr As String = ConfigurationManager.ConnectionStrings("MainConnStr").ConnectionString

#SQL SERVER CONNECTION STRING WEB CONFIG CODE#

You can reference this directly from code using: ASP.NET v2.0 has a couple new ways to reference connection strings stored in the web.config or nfig file.Ī typical web.config file in v2.0 could have the following section which is placed directly under the root section.









Sql server connection string web config