Config ConnectionStrings
Posted iwaityou
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了Config ConnectionStrings相关的知识,希望对你有一定的参考价值。
<connectionStrings>
<add name ="MyschoolConnectionString" connectionString ="Data Source =.;Initial Catalog = MySchool1;uid = sa;pwd = 123456"/>
</connectionStrings>
string connstr = ConfigurationManager.ConnectionStrings["MyschoolConnectionString"].ConnectionString;
引入configuartion
以上是关于Config ConnectionStrings的主要内容,如果未能解决你的问题,请参考以下文章
C#之app.configexe.config和vshost.exe.config作用区别