Click here to Skip to main content
65,938 articles
CodeProject is changing. Read more.
Articles / .NET

Get DataBase Connection Strings in Easy Way

1.00/5 (2 votes)
3 Mar 2011CPOL 8.6K  
I get it from the web.config via ConfigurationManager.ConnectionStrings;This makes it possible to keep all connectionstring settings in the web.config file.For example: http://www.dreamincode.net/code/snippet1676.htm[^].
I get it from the web.config via ConfigurationManager.ConnectionStrings;

This makes it possible to keep all connectionstring settings in the web.config file.

For example: http://www.dreamincode.net/code/snippet1676.htm[^].

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)