When using a Settings.settings file in .NET, where is the config actually stored?

后端 未结 10 767
予麋鹿
予麋鹿 2020-11-29 16:03

When using a Settings.settings file in .NET, where is the config actually stored? I want to delete the saved settings to go back to the default state, but can\'t find where

10条回答
  •  隐瞒了意图╮
    2020-11-29 17:01

    If your settings file is in a web app, they will be in teh web.config file (right below your project. If they are in any other type of project, they will be in the app.config file (also below your project).

    Edit

    As is pointed out in the comments: your design time application settings are in an app.config file for applications other than web applications. When you build, the app.config file is copied to the output directory, and will be named yourexename.exe.config. At runtime, only the file named yourexename.exe.config will be read.

提交回复
热议问题