System.Configuration.ConfigurationErrorsException: 项“xxxx”已添加。配置文件获取Configuration异常问题
<connectionStrings> <clear /> <add name="Sql" connectionString="User ID=sa;Data Source=1.;Password=123456;Initial Catalog=TestDB;Pooling=true;Max Pool Size=512;Min Pool Size=5;Connect Timeout=180000"/> </connectionStrings>
前面加上<clear/>节点即可