So how do you retrieve the customized properties of a .NET application from XML .config file? Can you automate this process ?



So how do you retrieve the customized properties of a .NET application from XML .config file? Can yo..

Answer / sudhanshu

Initialize an instance of AppSettingsReader class. Call the GetValue method of AppSettingsReader class, passing in the name of the property and the type expected. Assign the result to the appropriate variable. In Visual Studio yes, use Dynamic Properties for automatic .config creation, storage and retrieval.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More C Sharp Interview Questions

What are the Types of values mode can hold session state in web.config

0 Answers   BirlaSoft,


What is the difference between String s(Small s) and String S(Capital S)?

4 Answers  


if i used stored procedure for retrieving the data from sql server.in front end i had used data reader.when 100 records are there in table.when it has displayed ten records in frontend database has been collapsed.then where should our data available...

2 Answers   CybAge, Wipro,


Explain constructor.

7 Answers   Wipro,


How to generate strong name key file or which command is used to generated strong name key file?

0 Answers   CitiusTech,






What are the Types of caching

0 Answers   TCS,


Hello Friends..am Mohammed riyash..final year BCA in Jamal Mohamed College 2009. Trichy. My doubt is while connecting SQL2005 Built in Database withing the Visual Studio 2005 Framework.. I am getting the error.. That " An Error occurred and it may be due to , under the default settings of the Server, the connection cannot be established.." But the code works in MS Access for me.. Both in VB.Net and C#.Net am getting the same error.. Any genius please Message me to 9994558822 or mail me.. riyash.ips@gmail.com

3 Answers  


Describe the difference between inline and code behind - which is best?

0 Answers   Siebel,


What?s an abstract class?

5 Answers   Siebel,


Explain how do you directly call a native function exported from a dll?

0 Answers  


What is the use of list in c#?

0 Answers  


Is list a collection c#?

0 Answers  


Categories