<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://forums.asp.net/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Client Side Web Development</title><link>http://forums.asp.net/130.aspx</link><description>Client-side programming discussions, including CSS, DHTML, JScript/Javascript, etc. &lt;a href="http://aspadvice.com/SignUp/list.aspx?l=18&amp;c=16" target="_blank"&gt;Email List&lt;/a&gt;</description><dc:language>en</dc:language><generator>CommunityServer 2007 SP1 (Build: 20510.895)</generator><item><title>Re: Reading from web.config</title><link>http://forums.asp.net/thread/3496240.aspx</link><pubDate>Thu, 05 Nov 2009 14:58:08 GMT</pubDate><guid isPermaLink="false">4c671506-2930-414c-a40b-8bf57ded5924:3496240</guid><dc:creator>nitro-gl</dc:creator><slash:comments>0</slash:comments><comments>http://forums.asp.net/thread/3496240.aspx</comments><wfw:commentRss>http://forums.asp.net/commentrss.aspx?SectionID=130&amp;PostID=3496240</wfw:commentRss><description>&lt;p&gt;Hi, I have the same problem.&lt;/p&gt;
&lt;p&gt;I solve the problem.&lt;/p&gt;
&lt;p&gt;It was because by default aspx page using VB, so I have only&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;font size="2"&gt;
&lt;p&gt;&amp;lt;%&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;@&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; &lt;/font&gt;&lt;font color="#a31515" size="2"&gt;&lt;font color="#a31515" size="2"&gt;Page&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; &lt;/font&gt;&lt;font color="#ff0000" size="2"&gt;&lt;font color="#ff0000" size="2"&gt;Title&lt;/font&gt;&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;=&amp;quot;archive&amp;quot;&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt;%&amp;gt; in the top of aspx page ))&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font size="2"&gt;when i correct the page directive to&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;
&lt;p&gt;&lt;font size="2"&gt;
&lt;p&gt;&amp;lt;%&lt;/p&gt;
&lt;p&gt;&lt;/font&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;@&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; &lt;/font&gt;&lt;font color="#a31515" size="2"&gt;&lt;font color="#a31515" size="2"&gt;Page&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; &lt;/font&gt;&lt;font color="#ff0000" size="2"&gt;&lt;font color="#ff0000" size="2"&gt;Title&lt;/font&gt;&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;=&amp;quot;archive&amp;quot;&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; &lt;/font&gt;&lt;font color="#ff0000" size="2"&gt;&lt;font color="#ff0000" size="2"&gt;Language&lt;/font&gt;&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;=&amp;quot;C#&amp;quot;&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt;%&amp;gt;&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;font size="2"&gt;&lt;/font&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;font size="2"&gt;my code &lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;
&lt;p&gt;&amp;lt;&lt;/p&gt;
&lt;p&gt;&lt;/font&gt;&lt;/font&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;font color="#a31515" size="2"&gt;&lt;font color="#a31515" size="2"&gt;a&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; &lt;/font&gt;&lt;font color="#ff0000" size="2"&gt;&lt;font color="#ff0000" size="2"&gt;class&lt;/font&gt;&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;=&amp;quot;textlink&amp;quot;&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; &lt;/font&gt;&lt;font color="#ff0000" size="2"&gt;&lt;font color="#ff0000" size="2"&gt;href&lt;/font&gt;&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;=&amp;quot;&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt;&amp;lt;%= ConfigurationManager.AppSettings[&amp;quot;NewsAdministration&amp;quot;]%&amp;gt;&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;index.aspx&amp;quot;&amp;gt;&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; Admin&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;&amp;lt;/&lt;/font&gt;&lt;/font&gt;&lt;font color="#a31515" size="2"&gt;&lt;font color="#a31515" size="2"&gt;a&lt;/font&gt;&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;&amp;gt;&lt;br /&gt;works fine for me.&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font color="#0000ff" size="2"&gt;I hope its help to somebody )) sorry for my &lt;/font&gt;english&lt;font color="#0000ff" size="2"&gt; )&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;</description></item><item><title>Re: Reading from web.config</title><link>http://forums.asp.net/thread/2940736.aspx</link><pubDate>Fri, 13 Feb 2009 21:55:22 GMT</pubDate><guid isPermaLink="false">4c671506-2930-414c-a40b-8bf57ded5924:2940736</guid><dc:creator>asplikebutter</dc:creator><slash:comments>0</slash:comments><comments>http://forums.asp.net/thread/2940736.aspx</comments><wfw:commentRss>http://forums.asp.net/commentrss.aspx?SectionID=130&amp;PostID=2940736</wfw:commentRss><description>&lt;p&gt;I need to do the same thing reading the value of a Key in web.config but to assing a expression to a validator&amp;nbsp; &lt;/p&gt;
&lt;p&gt;how can I do this in ASP&lt;/p&gt;</description></item><item><title>Re: Reading from web.config</title><link>http://forums.asp.net/thread/2760001.aspx</link><pubDate>Fri, 21 Nov 2008 11:15:44 GMT</pubDate><guid isPermaLink="false">4c671506-2930-414c-a40b-8bf57ded5924:2760001</guid><dc:creator>Andreas Paulsson</dc:creator><slash:comments>0</slash:comments><comments>http://forums.asp.net/thread/2760001.aspx</comments><wfw:commentRss>http://forums.asp.net/commentrss.aspx?SectionID=130&amp;PostID=2760001</wfw:commentRss><description>&lt;p&gt;&amp;nbsp;Make sure that you have a reference to System.Configuration in your project.&lt;br /&gt;&lt;/p&gt;</description></item><item><title>Re: Reading from web.config</title><link>http://forums.asp.net/thread/2759908.aspx</link><pubDate>Fri, 21 Nov 2008 10:37:13 GMT</pubDate><guid isPermaLink="false">4c671506-2930-414c-a40b-8bf57ded5924:2759908</guid><dc:creator>vaibhavgangal</dc:creator><slash:comments>0</slash:comments><comments>http://forums.asp.net/thread/2759908.aspx</comments><wfw:commentRss>http://forums.asp.net/commentrss.aspx?SectionID=130&amp;PostID=2759908</wfw:commentRss><description>&lt;p&gt;Hi,&lt;/p&gt;&lt;p&gt;I have tried following code but gave error &amp;quot;Identifier expected&amp;quot;.&lt;br /&gt;&lt;/p&gt;&lt;p&gt;var imgval = &amp;#39;&amp;lt;%=System.Configuration.ConfigurationManager.AppSettings[&amp;quot;ImageSrcToken&amp;quot;].ToString() %&amp;gt;&amp;#39;;&lt;br /&gt;&lt;/p&gt;&lt;p&gt;Any idea what this error is?&lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;Regards,&lt;/p&gt;&lt;p&gt;Vaibhav&lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;</description></item><item><title>Re: Reading from web.config</title><link>http://forums.asp.net/thread/2271075.aspx</link><pubDate>Wed, 02 Apr 2008 09:06:56 GMT</pubDate><guid isPermaLink="false">4c671506-2930-414c-a40b-8bf57ded5924:2271075</guid><dc:creator>NHOQUE</dc:creator><slash:comments>0</slash:comments><comments>http://forums.asp.net/thread/2271075.aspx</comments><wfw:commentRss>http://forums.asp.net/commentrss.aspx?SectionID=130&amp;PostID=2271075</wfw:commentRss><description>&lt;p&gt;You may try the following:&lt;/p&gt;
&lt;p&gt;I tried it in my ASP.NET 2.0 and got the result.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;var MyVar=&amp;#39;&amp;lt;%= &lt;strong&gt;System.Configuration.ConfigurationManager&lt;/strong&gt;.AppSettings&lt;strong&gt;[&lt;/strong&gt;&amp;quot;PathLogout&amp;quot;&lt;strong&gt;]&lt;/strong&gt;.ToString()%&amp;gt;&amp;#39;&lt;/p&gt;</description></item><item><title>Re: Reading from web.config</title><link>http://forums.asp.net/thread/2232362.aspx</link><pubDate>Fri, 14 Mar 2008 05:46:00 GMT</pubDate><guid isPermaLink="false">4c671506-2930-414c-a40b-8bf57ded5924:2232362</guid><dc:creator>arunthomasarun</dc:creator><slash:comments>0</slash:comments><comments>http://forums.asp.net/thread/2232362.aspx</comments><wfw:commentRss>http://forums.asp.net/commentrss.aspx?SectionID=130&amp;PostID=2232362</wfw:commentRss><description>&lt;font size="2"&gt;
&lt;p&gt;Try this&amp;nbsp;&lt;/p&gt;
&lt;p&gt;ClientScript.RegisterClientScriptBlock(&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;this&lt;/font&gt;&lt;font size="2"&gt;.GetType(), &lt;/font&gt;&lt;font color="#800000" size="2"&gt;&amp;quot;maxAge&amp;quot;&lt;/font&gt;&lt;font size="2"&gt;, &lt;/font&gt;&lt;font color="#800000" size="2"&gt;&amp;quot;&amp;lt;script language=&amp;#39;javascript&amp;#39;&amp;gt;var maxAge=&amp;#39;&amp;quot;&lt;/font&gt;&lt;font size="2"&gt; + &lt;/font&gt;&lt;font color="#008080" size="2"&gt;ConfigurationManager&lt;/font&gt;&lt;font size="2"&gt;.AppSettings[&lt;/font&gt;&lt;font color="#800000" size="2"&gt;&amp;quot;test&amp;quot;&lt;/font&gt;&lt;font size="2"&gt;].ToString() + &lt;/font&gt;&lt;font color="#800000" size="2"&gt;&amp;quot;&amp;#39;;&amp;lt;/script&amp;gt;&amp;quot;&lt;/font&gt;&lt;font size="2"&gt;);&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font size="2"&gt;&lt;/font&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;font size="2"&gt;Thanks &lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font size="2"&gt;Arun&lt;/p&gt;&lt;/font&gt;</description></item><item><title>Re: Reading from web.config</title><link>http://forums.asp.net/thread/2201113.aspx</link><pubDate>Thu, 28 Feb 2008 11:12:44 GMT</pubDate><guid isPermaLink="false">4c671506-2930-414c-a40b-8bf57ded5924:2201113</guid><dc:creator>samerh</dc:creator><slash:comments>0</slash:comments><comments>http://forums.asp.net/thread/2201113.aspx</comments><wfw:commentRss>http://forums.asp.net/commentrss.aspx?SectionID=130&amp;PostID=2201113</wfw:commentRss><description>&lt;p&gt;I need to read the value of the key in a javascript found in my master page.&lt;/p&gt;
&lt;p&gt;i am writting this to read the &lt;font color="#800000"&gt;PathLogout&lt;/font&gt;:&lt;/p&gt;&lt;font color="#0000ff" size="2"&gt;var&lt;/font&gt;&lt;font size="2"&gt; t=&lt;/font&gt;&lt;font color="#800000" size="2"&gt;&amp;#39;&amp;lt;%=System.Configuration.ConfigurationManager.AppSettings(&amp;quot;PathLogout&amp;quot;).ToString() %&amp;gt;&amp;#39;&lt;/font&gt;&lt;font size="2"&gt;;&lt;/font&gt;&lt;font size="2"&gt; 
&lt;p&gt;window.open(t);&lt;/p&gt;
&lt;p&gt;when running my site it gives an error:&lt;/p&gt;
&lt;p&gt;&lt;em&gt;The Controls collection cannot be modified because the control contains code blocks (i.e. &amp;lt;% ... %&amp;gt;).&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;/font&gt;</description></item><item><title>Re: Reading from web.config</title><link>http://forums.asp.net/thread/2201060.aspx</link><pubDate>Thu, 28 Feb 2008 10:39:35 GMT</pubDate><guid isPermaLink="false">4c671506-2930-414c-a40b-8bf57ded5924:2201060</guid><dc:creator>JRICE</dc:creator><slash:comments>0</slash:comments><comments>http://forums.asp.net/thread/2201060.aspx</comments><wfw:commentRss>http://forums.asp.net/commentrss.aspx?SectionID=130&amp;PostID=2201060</wfw:commentRss><description>function test()
{
var t=&amp;#39;&amp;#39;
alert(t);
}

&lt;font size="2"&gt;&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;
&lt;p&gt;Heres a sample on how you read appsettings from javascript&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;lt;&lt;/font&gt;&lt;font color="#a31515" size="2"&gt;script&lt;/font&gt;&lt;font color="#000000" size="2"&gt; &lt;/font&gt;&lt;font color="#ff0000" size="2"&gt;type&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;=&amp;quot;text/javascript&amp;quot;&amp;gt;&lt;br /&gt;function&lt;/font&gt;&lt;font size="2"&gt;&lt;font color="#000000"&gt; test()&lt;br /&gt;&lt;/font&gt;{&lt;br /&gt;&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;var&lt;/font&gt;&lt;font color="#000000" size="2"&gt; t=&lt;/font&gt;&lt;font color="#a31515" size="2"&gt;&amp;#39;&amp;lt;%=ConfigurationManager.AppSettings(&amp;quot;test&amp;quot;).ToString() %&amp;gt;&amp;#39;&lt;br /&gt;&lt;/font&gt;&lt;font size="2"&gt;alert(t);&lt;br /&gt;}&lt;br /&gt;&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&amp;lt;/&lt;/font&gt;&lt;font color="#a31515" size="2"&gt;script&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&amp;gt;&lt;br /&gt;&lt;font color="#0000ff" size="2"&gt;&amp;lt;&lt;/font&gt;&lt;font color="#a31515" size="2"&gt;input&lt;/font&gt;&lt;font color="#000000" size="2"&gt; &lt;/font&gt;&lt;font color="#ff0000" size="2"&gt;type&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;=&amp;quot;Submit&amp;quot;&lt;/font&gt;&lt;font color="#000000" size="2"&gt; &lt;/font&gt;&lt;font color="#ff0000" size="2"&gt;value&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;=&amp;quot;Save&amp;quot;&lt;/font&gt;&lt;font color="#000000" size="2"&gt; &lt;/font&gt;&lt;font color="#ff0000" size="2"&gt;onclick&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;=&amp;quot;test()&amp;quot;&lt;/font&gt;&lt;font color="#000000" size="2"&gt; &lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;/&amp;gt;&lt;br /&gt;&lt;br /&gt;&lt;font color="#0000ff" size="2"&gt;Web.Config&lt;br /&gt;&amp;lt;&lt;/font&gt;&lt;font color="#a31515" size="2"&gt;appSettings&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&amp;gt;&lt;br /&gt;&amp;lt;&lt;/font&gt;&lt;font color="#a31515" size="2"&gt;add&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt; &lt;/font&gt;&lt;font color="#ff0000" size="2"&gt;key&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;=&lt;/font&gt;&lt;font color="#000000" size="2"&gt;&amp;quot;&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;test&lt;/font&gt;&lt;font color="#000000" size="2"&gt;&amp;quot;&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt; &lt;/font&gt;&lt;font color="#ff0000" size="2"&gt;value&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;=&lt;/font&gt;&lt;font color="#000000" size="2"&gt;&amp;quot;&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;test2&lt;/font&gt;&lt;font color="#000000" size="2"&gt;&amp;quot;&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;/&amp;gt;&lt;br /&gt;&amp;lt;/&lt;/font&gt;&lt;font color="#a31515" size="2"&gt;appSettings&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&amp;gt;&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;HTH&lt;/p&gt;&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&lt;/font&gt;</description></item><item><title>Re: Reading from web.config</title><link>http://forums.asp.net/thread/2200971.aspx</link><pubDate>Thu, 28 Feb 2008 09:54:51 GMT</pubDate><guid isPermaLink="false">4c671506-2930-414c-a40b-8bf57ded5924:2200971</guid><dc:creator>samerh</dc:creator><slash:comments>0</slash:comments><comments>http://forums.asp.net/thread/2200971.aspx</comments><wfw:commentRss>http://forums.asp.net/commentrss.aspx?SectionID=130&amp;PostID=2200971</wfw:commentRss><description>&lt;p&gt;iam using 2.0&lt;/p&gt;
&lt;p&gt;i did try it but it didnt work. Are u sure that is is working? &lt;/p&gt;
&lt;p&gt;used this &lt;/p&gt;&lt;font size="2"&gt;&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;var&lt;/font&gt;&lt;font size="2"&gt; MyVar = &lt;/font&gt;&lt;font color="#800000" size="2"&gt;&amp;#39;&amp;lt;%$ System.Configuration.ConfigurationManager.AppSettings:PathLogout%&amp;gt;&amp;#39;&lt;/font&gt;&lt;font size="2"&gt;; &lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt;
&lt;p&gt;alert(MyVar.value);&lt;/p&gt;&lt;/font&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;</description></item><item><title>Re: Reading from web.config</title><link>http://forums.asp.net/thread/2200950.aspx</link><pubDate>Thu, 28 Feb 2008 09:41:14 GMT</pubDate><guid isPermaLink="false">4c671506-2930-414c-a40b-8bf57ded5924:2200950</guid><dc:creator>Andreas Paulsson</dc:creator><slash:comments>0</slash:comments><comments>http://forums.asp.net/thread/2200950.aspx</comments><wfw:commentRss>http://forums.asp.net/commentrss.aspx?SectionID=130&amp;PostID=2200950</wfw:commentRss><description>&lt;p&gt;Are You using .NET 2.0 or later?&lt;/p&gt;&lt;p&gt;Use&lt;/p&gt;&lt;pre class="coloredcode"&gt;alert (&amp;quot;test&amp;quot;);&lt;br /&gt;var MyVar = &amp;#39;&lt;span class="dir"&gt;&amp;lt;%$&lt;/span&gt; System.Configuration.&lt;b&gt;ConfigurationManager&lt;/b&gt;.AppSettings:PathLogout&lt;span class="dir"&gt;%&amp;gt;&lt;/span&gt;&amp;#39;; &lt;br /&gt;alert(MyVar.value);&lt;/pre&gt;&lt;p&gt;instead.&amp;nbsp;&lt;/p&gt;</description></item><item><title>Re: Reading from web.config</title><link>http://forums.asp.net/thread/2200945.aspx</link><pubDate>Thu, 28 Feb 2008 09:39:35 GMT</pubDate><guid isPermaLink="false">4c671506-2930-414c-a40b-8bf57ded5924:2200945</guid><dc:creator>samerh</dc:creator><slash:comments>0</slash:comments><comments>http://forums.asp.net/thread/2200945.aspx</comments><wfw:commentRss>http://forums.asp.net/commentrss.aspx?SectionID=130&amp;PostID=2200945</wfw:commentRss><description>&lt;p&gt;i have tried to add a hidden field and read the key from it&lt;/p&gt;&lt;font size="2"&gt;
&lt;p&gt;&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&amp;lt;&lt;/font&gt;&lt;font color="#800000" size="2"&gt;asp&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;:&lt;/font&gt;&lt;font color="#800000" size="2"&gt;HiddenField&lt;/font&gt;&lt;font size="2"&gt; &lt;/font&gt;&lt;font color="#ff0000" size="2"&gt;ID&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;=&amp;quot;HiddenField1&amp;quot;&lt;/font&gt;&lt;font size="2"&gt; &lt;/font&gt;&lt;font color="#ff0000" size="2"&gt;runat&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;=&amp;quot;server&amp;quot;&lt;/font&gt;&lt;font size="2"&gt; &lt;/font&gt;&lt;font color="#ff0000" size="2"&gt;Value&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;=&amp;quot;&lt;/font&gt;&lt;font size="2"&gt;&amp;lt;%$AppSettings:PathLogout %&amp;gt;&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&amp;quot;&lt;/font&gt;&lt;font size="2"&gt; &lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;/&amp;gt;&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font color="#0000ff" size="2"&gt;then in JS&lt;/font&gt;&lt;/p&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font size="2"&gt;&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;var&lt;/font&gt;&lt;font size="2"&gt; myVar = document.getElementById(&lt;/font&gt;&lt;font color="#800000" size="2"&gt;&amp;#39;&amp;lt;%= HiddenField1.ClientID %&amp;gt;&amp;#39;&lt;/font&gt;&lt;font size="2"&gt;).value;&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; 
&lt;p&gt;but giving an error&lt;/p&gt;
&lt;p&gt;The expression prefix &amp;#39;System.Configuration.ConfigurationManager.AppSettings&amp;#39; was not recognized.&amp;nbsp; Please correct the prefix or register the prefix in the &amp;lt;expressionBuilders&amp;gt; section of configuration.&lt;/p&gt;
&lt;p&gt;please note that i have added &lt;/p&gt;&lt;font color="#0000ff" size="2"&gt;
&lt;p&gt;&amp;lt;&lt;/font&gt;&lt;font color="#800000" size="2"&gt;add&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt; &lt;/font&gt;&lt;font color="#ff0000" size="2"&gt;namespace&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;=&lt;/font&gt;&lt;font color="#000000" size="2"&gt;&amp;quot;&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;System.Configuration.ConfigurationManager&lt;/font&gt;&lt;font color="#000000" size="2"&gt;&amp;quot;&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;/&amp;gt;&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font color="#0000ff" size="2"&gt;in namespaces in web.config and code behind of the page&lt;/p&gt;&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;</description></item><item><title>Re: Reading from web.config</title><link>http://forums.asp.net/thread/2200928.aspx</link><pubDate>Thu, 28 Feb 2008 09:30:16 GMT</pubDate><guid isPermaLink="false">4c671506-2930-414c-a40b-8bf57ded5924:2200928</guid><dc:creator>samerh</dc:creator><slash:comments>0</slash:comments><comments>http://forums.asp.net/thread/2200928.aspx</comments><wfw:commentRss>http://forums.asp.net/commentrss.aspx?SectionID=130&amp;PostID=2200928</wfw:commentRss><description>&lt;p&gt;Iam using this in my javascript but still getting same error :(&lt;/p&gt;
&lt;p&gt;&amp;nbsp;alert (&amp;quot;test&amp;quot;);&lt;br /&gt;&lt;font color="red"&gt;&amp;nbsp;var MyVar = &amp;#39;&amp;lt;%$ System.Configuration.ConfigurationSettings.AppSettings:PathLogout%&amp;gt;&amp;#39;;&amp;nbsp;&lt;br /&gt;&lt;/font&gt;alert(MyVar.value);&lt;br /&gt;&lt;/p&gt;</description></item><item><title>Re: Reading from web.config</title><link>http://forums.asp.net/thread/2200905.aspx</link><pubDate>Thu, 28 Feb 2008 09:16:32 GMT</pubDate><guid isPermaLink="false">4c671506-2930-414c-a40b-8bf57ded5924:2200905</guid><dc:creator>Mulukutla</dc:creator><slash:comments>0</slash:comments><comments>http://forums.asp.net/thread/2200905.aspx</comments><wfw:commentRss>http://forums.asp.net/commentrss.aspx?SectionID=130&amp;PostID=2200905</wfw:commentRss><description>&lt;p&gt;hey, try giving like this Configuration.ConfigurationManager.AppSettings:&amp;quot;KEY&amp;quot; in text binding.&lt;/p&gt;&lt;p&gt;i think this may work for u.&lt;/p&gt;&lt;p&gt;Regards,&lt;/p&gt;&lt;p&gt;Mulukutla&lt;img src="http://forums.asp.net/emoticons/emotion-11.gif" alt="Cool" /&gt;&amp;nbsp;&lt;/p&gt;</description></item><item><title>Re: Reading from web.config</title><link>http://forums.asp.net/thread/2200893.aspx</link><pubDate>Thu, 28 Feb 2008 09:07:50 GMT</pubDate><guid isPermaLink="false">4c671506-2930-414c-a40b-8bf57ded5924:2200893</guid><dc:creator>samerh</dc:creator><slash:comments>0</slash:comments><comments>http://forums.asp.net/thread/2200893.aspx</comments><wfw:commentRss>http://forums.asp.net/commentrss.aspx?SectionID=130&amp;PostID=2200893</wfw:commentRss><description>&lt;p&gt;Iam getting this error&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Parser Error Message: &lt;/strong&gt;Literal expressions like &amp;#39;&amp;lt;%$ AppSettings:PathLogout%&amp;gt;&amp;#39; are not allowed. Use &amp;lt;asp:Literal runat=&amp;quot;server&amp;quot; Text=&amp;quot;&amp;lt;%$ AppSettings:PathLogout%&amp;gt;&amp;quot; /&amp;gt; instead.&lt;br /&gt;&lt;/p&gt;</description></item><item><title>Re: Reading from web.config</title><link>http://forums.asp.net/thread/2200873.aspx</link><pubDate>Thu, 28 Feb 2008 08:58:28 GMT</pubDate><guid isPermaLink="false">4c671506-2930-414c-a40b-8bf57ded5924:2200873</guid><dc:creator>Andreas Paulsson</dc:creator><slash:comments>0</slash:comments><comments>http://forums.asp.net/thread/2200873.aspx</comments><wfw:commentRss>http://forums.asp.net/commentrss.aspx?SectionID=130&amp;PostID=2200873</wfw:commentRss><description>&lt;p&gt;When using expression builders in an aspx page, use the &amp;lt;%$ expression prefix: expression value %&amp;gt; syntax. See http://www.beansoftware.com/ASP.NET-Tutorials/Expression-Builder.aspx for more details.&lt;/p&gt;&lt;p&gt;So You should use &amp;nbsp;&lt;/p&gt;&lt;p&gt;var MyVar = &amp;#39;&amp;lt;%&lt;b&gt;$&lt;/b&gt; AppSettings:&lt;font color="#0000ff"&gt;PathLogout&lt;/font&gt;%&amp;gt;&amp;#39;; &lt;/p&gt;&lt;p&gt;instead.&lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;</description></item></channel></rss>