How to get values from custom config section?

  • Thread starter Thread starter Showjumper
  • Start date Start date
S

Showjumper

Given this custom config section:
<HttpResourceHandlerSettings compressionOn="true" daysInCache="30">
<fileSets>
<add name="FileSet_CSS_Style1"
value="~/styles/rdstyles.css,~/styles/thickbox.css" />
<add name="FileSet_AdminCSS_Style1"
value="~/styles/rdstyles.css,~/styles/StyleSheet.css" />
<add name="FileSet_JS_Functionality1"
value="~/scripts/jquery.js,~/scripts/thickbox.js" />
</fileSets>
</HttpResourceHandlerSettings>

I want to retrieve the value for a given name i.e.something like the
following pseudocode:
settings.FileSets.Name("FileSet_" & fileSet).value where fileSet is a
querystring value -
Dim fileSet As String = Context.Request.QueryString("fileSet") and a sample
link tag -
<link type="text/css"
href="resourcehandler.aspx?fileSet=CSS_Style1&type=text/css"
rel="Stylesheet"/>

All this is to be functionally equiv to
ConfigurationManager.AppSettings(("FileSet_" + fileSet))

This possible?

Ashok Padmanabhan DVM
Thank you...
 
Back
Top