<appSettings>
<t title="t1" text="text1" xx="xxx1" />
<t title="t2" text="text2" xx="xxx2" />
</appSettings>怎么读出值啊? public NameValueCollection GetWebConfig(string _Key)
{
object settings = ConfigurationSettings.GetConfig(_Key);
NameValueCollection nvc = settings as NameValueCollection;
return nvc;
}//GetWebConfig("appSettings/t");
<t title="t1" text="text1" xx="xxx1" />
<t title="t2" text="text2" xx="xxx2" />
</appSettings>怎么读出值啊? public NameValueCollection GetWebConfig(string _Key)
{
object settings = ConfigurationSettings.GetConfig(_Key);
NameValueCollection nvc = settings as NameValueCollection;
return nvc;
}//GetWebConfig("appSettings/t");
<add key="Name" value="value"/>
</appSettings>
ConfigurationManager.AppSettings["name"].ToString()如果ASP.net 1.1
ConfigurationSettings.AppSettings["name"].ToString()
<section name="MyToken" type="System.Configuration.SingleTagSectionHandler,System" />
</configSections>我后来用了这个,我是需要自定义节点的,谢谢大家!
<section name="MyToken" type="System.Configuration.SingleTagSectionHandler,System" />
</configSections>我后来用了这个,我是需要自定义节点的,谢谢大家!
有没有源码,贴出来看看阿