How to determine the current list of default configuration sections in the config file (* .exe.config or web.config) .NET application? Such as appSettings?
- Uh ... What is the current default list of sections? - Athari
- @Athari well, sections like appSettings, connectionStrings, system.diagnostics or system.web. Current - this means it can be corrected. - mals
- How to fix? What exactly do you want to do? And what does "default" mean? - Athari
|
2 answers
The list of sections by default is in the configuration file at the computer or server level.
And if you get the following message in the application:
System.Configuration.ConfigurationErrorsException: Configuration system failed to initialize ---> System.Configuration.ConfigurationErrorsException: Unrecognized configuration section system.diagnostics.
It is possible that someone tampered your machine.config file. In this case, delete the declaration section of the system.diagnostics.
|
My.Settings.Properties... returns a collection of parameter properties in a wrapper
- as far as I know,
My.Settings.Propertiesis a feature of projects for VB.NET, is encoded in the hidden class Settings.Designer.vb and is related to the Settings tab in the properties of a VB.NET project. Is not it? - mals - Tooting. You can create a separate file and assign it to a variable, because it is created as a class. (Dim s As Settings1) If you don’t need VB.NET, you can search it on MSDN as it does in other .NET languages - IvanZakirov
|