The System.Configuration is a .net framework namespace contains the types that provide the programming model for handling configuration data.
Questions tagged [system.configuration]
88 questions
1
vote
1 answer
The best way to get a path to machine.config of a different .NET version
Whats the best way to get a path to .net 2.0 machine.config file, if the application is running on .net 4.0?
One way would be to do string manipulation and file system access to replace v4.0* with v2.0* in
new…

kateroh
- 4,382
- 6
- 43
- 62
1
vote
1 answer
ConfigurationManager not saving value in app.config
I have this statement, that's supposed to set the value of a key in my config:
ConfigurationManager.AppSettings["Volume"] = volumeNumSlider.Value.ToString();
But it does not save the value when I relaunch the application.
This is my…

dvs
- 97
- 1
- 8
1
vote
2 answers
How to delete network interface of MAC using Objective C
I am working on MAC Application in which i have to create VPN Connection through my application.
I am able to create VPN connection successfully but now I want to delete the interface which was created by my application in network of System…

Malav Soni
- 2,739
- 1
- 23
- 52
1
vote
0 answers
App.config working with custom sections
I seem to be having some trouble identifying exactly how to verbally express what I'm trying to learn how to interact with. This is problematic from a search standpoint. I have been trying a variety of queries to find something related to the topic…

EnergyWasRaw
- 134
- 8
1
vote
1 answer
ConfigurationProperty not returning DefaultValue incase it doesnt exist
[ConfigurationProperty("spatialSRID", DefaultValue = 4326)]
public int SpatialSRID
{
get { return (int)this["SpatialSRID"]; }
set { this["SpatialSRID"] = value; }
}
My understand of the above code is that if I do not define the section…

Zoinky
- 4,083
- 11
- 40
- 78
1
vote
1 answer
Is it possible to read XML using System.Configuration
Currently i am using XElement for parsing XML and read each node which required by application.
Now i want to read XML by using System.Configuration.Is this possible, what i think.My config.xml have not any configuration section.It just plain…

Neeraj Dubey
- 4,401
- 8
- 30
- 49
1
vote
0 answers
PowerShell load app.config into current domain
Got a bit of a query regarding loading a type that depends on a configuration file in PowerShell; I know you can load the file on the fly using the below with a fully qualified path:
[System.AppDomain]::CurrentDomain.SetData('APP_CONFIG_FILE',…

milquetoastable
- 176
- 9
1
vote
1 answer
How to declare ConfigurationManager.ConnectionStrings?
hello i'm using visual studio 2008, vb.net and oracle as my db.
this is what i save in my apps.config
and this is my code for calling the…

Husna5207
- 449
- 3
- 10
- 28
1
vote
0 answers
Custom Configuration Section - Multiple Collections
Possible Duplicate:
How to Create a Configuration Section That Contains a Collection of Collections?
I would like to create something like this custom section in a web.config
-

Mikeb
- 781
- 7
- 24
0
votes
1 answer
SingleTagSectionHandler returned as DefaultSection
I have an App.conf file which contains:

Michiel Alders
- 69
- 1
- 2
- 15
0
votes
0 answers
Ability to use classes in System.Configuration disappeared after unrelated change
I have a C# library project that was building correctly in Visual Studio 2022, using .NET Standard 2.1. In it I use System.Configuration.ConfifurationSection and related items to read the project config.
Yesterday I switched from using Log4net for…

Stanley Friesen
- 1
- 1
0
votes
0 answers
How can I create a NuGet package that uses both .NET Framework and .NET Core configuration?
I'm trying to allow the constructor to accept IConfiguration for .Net, and a reference to ConfigurationManager or similar for .Net Framework/Standard.
I am trying to create a conditional constructor for a class that needs to know which runtime it's…

user3012708
- 793
- 1
- 11
- 33
0
votes
0 answers
Add new ConfigurationElement in ConfigurationElementCollection throws Read-only exception
I have a .config file, where i need to add new ConfigurationElement under the ConfigurationElementCollection, I have followed the documentation of microsoft and implemented everything…

Dharun
- 15
- 7
0
votes
2 answers
ConfigurationManager throwing null exception when trying to read connection string in .NET 4.0
I am working on .NET Framework 4.0 Class Library project along with ADO.NET. I have connectionString inside the App.config which I am trying to read using ConfigurationManager but getting null reference exception.
Error
app.config

K.Z
- 5,201
- 25
- 104
- 240
0
votes
1 answer
Unable to load .NET config sections into System.Configuration classes within an aws lambda function
I would like to deploy an AWS lambda function using .NET Core. Much of the code is shared with other applications that are not lambdas. We use System.Configuration extensively throughout our code. However, we are unable to get lambda code to find…

Kevin MacDonald
- 650
- 8
- 21