How do you modify the web.config appSettings at runtime?

后端 未结 7 1802
小鲜肉
小鲜肉 2020-11-22 14:28

I am confused on how to modify the web.config appSettings values at runtime. For example, I have this appSettings section:


  

        
7条回答
  •  挽巷
    挽巷 (楼主)
    2020-11-22 14:35

    Changing the web.config generally causes an application restart.

    If you really need your application to edit its own settings, then you should consider a different approach such as databasing the settings or creating an xml file with the editable settings.

提交回复
热议问题