Questions tagged [configsection]

Specifies configuration section and namespace declarations.

47 questions
2
votes
1 answer

C# configSections "Sections must only appear once per config file."

I want to create a "List" of clientUsers that contains many of clientUser
SexyMF
  • 10,657
  • 33
  • 102
  • 206
2
votes
1 answer

missing a section declaration

I've done the following in the Web.config
Helbo
  • 473
  • 10
  • 32
2
votes
3 answers

Is it possible to define in a dependent dll's application config

I have a custom .NET addin for an application and I am trying to create configSections for the addin's config file. The trouble is I am not able to read that section If load the configuration using the…
dotnetcoder
2
votes
3 answers

app.config custom configuration - 'System.TypeInitializationException'

I tried following this instruction app.config Custom Configuration However, i got stuck. This is my app.config code:
lynx
  • 45
  • 1
  • 7
2
votes
1 answer

How to use multiple locations for configSource in config file for WCF Client

Our application will act as client for different WCF-services in the future. At the moment we consume only one WCF-Service. Our config-file for the application is set up using configSource-attribues at the moment:
ManOnAMission
  • 1,023
  • 1
  • 12
  • 31
2
votes
1 answer

ConfigurationManager.GetSection always gives object with default values

Here is the ConfigurationSection class using System.Configuration; namespace CampusWebStore.Config { public class PoolerConfig : ConfigurationSection { [ConfigurationProperty("PoolId", IsRequired = true)] public string…
pixelshaded
  • 313
  • 1
  • 2
  • 10
2
votes
1 answer

Custom config section with two differentt child collections

I'm having trouble finding/figuring out how to map the following custom config section:
Paul Fleming
  • 24,238
  • 8
  • 76
  • 113
1
vote
1 answer

app.settings custom configuration issue

I've attempted my first go round with a custom configuration in app.settings. When I try to call the config I get "Unrecognized configuration section servers". What am I doing wrong?
Dovey
  • 43
  • 1
  • 6
1
vote
0 answers

How can I get all the properties from a ConfigSection in C#

(after all, sorry for my english) I need to ask you how can I get the key value pair from a ConfigSection in c#. I´m creating a DLL which take the config file from the executable, from this configfile I need a particular SectionGroup called…
1
vote
1 answer

Implementing custom configuration section handler

gleanings from a variety of sources (including stackOverlflow), however when I come to use it, I get the following error message "The Configuration property 'deviceconfig' may not be derived from ConfigurationSection." I have been struggling with…
1
vote
1 answer

How to get app.config value with using custom config sections...?

I want to get server address value, but I received a null reference exception in Alert method: Values.Server.Key["CollectorServer"].Address -> null reference exception My app.config looks like this:
1
vote
1 answer

Read an attribute "type" from a custom
node in web.config

I've defined my own and
elements in the web.config. One of the parameters that I need to specify via my custom
is a Type. For example, I currently have
awj
  • 7,482
  • 10
  • 66
  • 120
1
vote
1 answer

How can I dynamically provide command line arguments during VS 2012 C# debug sessions?

I am busy with a console application, being a CLI to an API class that provides top level public methods for a data integration process. During development, it is necessary for me to frequently change the command line arguments in the project…
ProfK
  • 49,207
  • 121
  • 399
  • 775
1
vote
2 answers

app/web config custom sections, collection elements with attributes

I thought this would be something simple to do, as I have an xml section like:
Grofit
  • 17,693
  • 24
  • 96
  • 176
1
vote
1 answer

How to change configSections, section, type element? Specifically Version

I'm posting my question here and to CodeProject, as a question to the famous article series on the mysteries of config files. From the article: Optionally, you may specify culture, version and public key (for signed assemblies) values if you…
TonyG
  • 1,432
  • 12
  • 31