Adding Access Database Connection String in web.config file
ASP.NET September 1, 2012 Comments Off on Adding Access Database Connection String in web.config fileHi here is a small snippet. If you have your access database in your app_data folder and need to add its connection string in the web.config file, so that you can use in your business tier or code behind, here is the snippet.
<connectionStrings> <remove name="LocalSqlServer"/> <add name="AccessConnectionString" connectionString="Provider=Microsoft.Jet.OLEDB.4.0;Data Source=|DataDirectory|AccessDatabase.mdb" providerName="System.Data.OleDb"/> </connectionStrings>