开发者

How to get application settings path in winforms?

In Settings.Settings in Winforms I have some User settings, and I must clean up them.

I can't do it by:

Sett开发者_如何学运维ings.Default.SomeUserSettings = null;

It must be done by hand .

So, where can I find those settings ?

I'm using windows 7.

Or maybe you know some application, from which I can find last edited files?


Look in the folder of your application, there is a XML file named yourAppName.exe.config. This is where the user settings are saved.

To get the path you can use :

string path = AppDomain.CurrentDomain.SetupInformation.ConfigurationFile;


If you intend to do it by hand then In the Application Folder(The folder where the application is installed) or Debug folder(if you are running Visual Studio Solution) you would see the File with Extension of Name.exe.config Open it with notepad or dreamweaver and see the XML there it would be something like

<Mark_V1._0.myAppSett>
  <setting name="validated" serializeAs="Bool">
     <value>False</value>
  </setting>
</Mark_V1._0.myAppSett>

Modify the <value > tag to change the value

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜