473,507 Members | 12,744 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Iterating Across All Data in Configuration File

Hello,

Using ConfigurationSettings.AppSettings.keys I can iterate across the
default AppSettings section of the XML config file.

I need to iterate across all key value pairs in other sections as well.
If I use:

ConfigurationSettings.GetConfig("path..") as Hashtable;

it doesn't seem to work. Is there any way to do this?

Dec 20 '05 #1
2 1514
You could open the file using an XmlReader. It is designed to iterate
over an XML document.
Dec 21 '05 #2
I found a solution, thanks all for help. It only took me 3 hrs...

In <configSection> specify your type as
"System.Configuration.DictionarySectionHandler ". Then
ConfigurationSettings.GetConfig(type) will return a hash.

Dec 21 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
1802
by: Antony Sequeira | last post by:
Hi I needed to share some configuration information across requests. The most straightforward way would be code it in a php file and include it in every other script. The problem with this...
1
2481
by: Jonathan Hayward | last post by:
Just after posting the previous request, I realised that my test case worked after I added flushes. The next problem I have is that, in the real program, the server gets an EOFError when it first...
12
11674
by: Matthew Wilson | last post by:
I'm playing around with genetic algorithms and I want to write a function that mutates an integer by iterating across the bits, and about 1 in 10 times, it should switch a zero to a one, or a one...
1
360
by: Raymond Cheung | last post by:
How do I disable to show xml file content on web browser from across domain. I know we can have some sort of enbcription on the xml file content. I also know that we can use authentication to...
7
1684
by: Dave Hansen | last post by:
OK, first, I don't often have the time to read this group, so apologies if this is a FAQ, though I couldn't find anything at python.org. Second, this isn't my code. I wouldn't do this. But a...
2
301
by: Mervin Williams | last post by:
I am using Infragistics UltraWebTab (a tab folder control for ASP.NET). My tab folder control will include five tab pages with a separate web form on each, and these web forms will share data. ...
0
249
by: shawnn | last post by:
Hello, Using ConfigurationSettings.AppSettings.keys I can iterate across the default AppSettings section of the XML config file. I need to iterate across all key value pairs in other sections...
13
1847
by: Eric Renken | last post by:
I currently use statements like this in my 1.1 code. System.Configuration.ConfigurationSettings.AppSettings I use this in DLLs that are referenced by the application. The application has this...
5
2683
by: =?Utf-8?B?VGhlIE1hbiBGcm9tIFNRTA==?= | last post by:
I'm having the darndest XML config file problem that I really need help with. I'm supporting a .NET 1.1 desktop application with its own config file, and I implement IConfigurationSectionHandler...
0
7221
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7313
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
1
7029
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
7481
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5619
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
4702
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
1537
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
758
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
411
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.