I’ve used the settings system in .NET before for a winforms app. However, what I wonder is what if I need to store settings of a custom type? Could I edit the settings designer-generated class file?
I read a thread on here about doing this and it wasn’t recommended (someone mentioned pressing F11 to open the file, or a similar key).
What can I do in this scenario?
Thanks
The designer generated class file will get lost on the next build. You’ll need to edit in the configuration view or in the xml file.
Depending on how much work you want to do, and what kind of behaviour you need, you can do something simple like manually defining a custom configuration section, with a simple wrapper class to access the settings.
On the other hand, there are tools like the Configuration Section Designer that can help…
Keep it as simple as you can though, especially if what you need to configure is relatively simple.