Вопрос

In order to save user settings in my app I am use the Settings.settings class. This is working fine for things like Username, Email, etc. The problem is that my app is a kind of multi app application and I need to dynamically create settings depending on which "app" the user is using at the time e.g. App1_BackgroundColor, App2_BackgroundColor, etc. I can't statically set these in the Settings.settings class because the user can add and remove "apps" to the application.

How can I create/save user settings on the fly that will persist after the application has been closed?

Это было полезно?

Решение 2

I ended up just creating my own settings xml file with nodes for each "app". I then just read/write to/from that file.

Другие советы

Antonio Nakić Alfirević has posted a very good article "Easier .Net Settings Management" on Code Project. It might be a better approach than using Settings designer.

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top