Configuration File

  • for windows application we usually use app.config, for web application web.config

Get Connection String

var connStr = ConfigurationManager.ConnectionStrings["MyConnStr"].ConnectionString;

Get App Settings

var settings = ConfigurationSettings.AppSettings["Mykey"];
programming/csharp/configfile.txt · Last modified: 2018-06-21 19:48 (external edit)
CC Attribution-Noncommercial-Share Alike 4.0 International
Driven by DokuWiki Recent changes RSS feed Valid CSS Valid XHTML 1.0