Do you mean a web site opening its own config file or a program opening a config file for any web site? If it's the former, the WebConfigurationManager class has an AppSettings property and a ConnectionStrings property, both of which can be indexed by key to get the corresponding value. If it's the latter, the same class can be used to open a specific config file and return a Configuration object, which also has the two aforementioned properties.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.