Using an external .config file in configSource produces error

前端 未结 4 1165
迷失自我
迷失自我 2021-01-04 01:35

I was playing around with how to use the Configuration Manager to read/write custom sections in the App.config file for a WPF application in C#. I read this excellent articl

4条回答
  •  迷失自我
    2021-01-04 02:17

    If the section you are making external is defined in configSections, you should place the configSource attribute in the element defining the section. Only the appSettings and connectionStrings sections (which don't need definitions in configSections) should have tags with configSource in the body of the main config file.

提交回复
热议问题