Winform Settings configuration File Save

Source: Internet
Author: User

To add an additional settings group

    • From the Project menu, choose Add New Item (adding the entry). The Add New Item dialog box opens.

    • In the "Add New Item" dialog box, select "Settings file".

    • In the Name box, name the settings file, such as Specialsettings.settings, and then click Add to add the file to the solution.

    • In the Solution Explorer (Solution Explorer), drag the new settings file into the Properties folder. This allows you to use the new settings in your code.

    • Add and use settings in this file as in any other settings file. This group setting can be accessed through the Properties.specialsettings object.


Scope:

Scope : Application scope and user scope. Settings with application scope represent settings that are used by the application regardless of user preferences, and settings with user scope are usually not important to the actual application, and they are likely to be associated with preferences or other non-critical values. The important difference between application scope settings and user scope settings is that user-scoped settings are read/write at run time and can be changed and saved in code. Application scope settings are read-only at run time. Although it can be read, it cannot be written to. Settings with application scope can only be changed at design time or by manually modifying the settings file.


save for user settings:The user settings information will be saved to a specific file in the system Tray E:\AppData directory. You can use the ProcMon tool to view.
attached code one: http://download.csdn.net/detail/ilipan/9009343

Copyright NOTICE: This article for Bo Master original article, without Bo Master permission not reproduced.

Winform Settings configuration File Save

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.