<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://forums.iis.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/" xmlns:cs="http://blogs.iis.net/"><channel><title>IIS7 - Configuration &amp; Scripting</title><link>http://forums.iis.net/1046.aspx</link><description>Forum aimed at understanding the system.Webserver or system.ApplicationHost using a text editor or scripting</description><dc:language>en</dc:language><generator>CommunityServer 2007 SP1 (Build: 20510.895)</generator><item><title>Re: section.OverrideMode = OverrideMode.Allow; ----&gt; "The request is not supported"</title><link>http://forums.iis.net/thread/1909983.aspx</link><pubDate>Sat, 11 Jul 2009 01:56:34 GMT</pubDate><guid isPermaLink="false">50bcf3b4-f6fe-4638-adff-0c150e922e99:1909983</guid><dc:creator>diegochb</dc:creator><slash:comments>0</slash:comments><comments>http://forums.iis.net/thread/1909983.aspx</comments><wfw:commentRss>http://forums.iis.net/commentrss.aspx?SectionID=1046&amp;PostID=1909983</wfw:commentRss><description>&lt;p&gt;&amp;nbsp;Thanks! I will have to wait until monday to test it :( !&lt;br /&gt;&lt;/p&gt;</description></item><item><title>Re: section.OverrideMode = OverrideMode.Allow; ----&gt; "The request is not supported"</title><link>http://forums.iis.net/thread/1909966.aspx</link><pubDate>Fri, 10 Jul 2009 21:36:42 GMT</pubDate><guid isPermaLink="false">50bcf3b4-f6fe-4638-adff-0c150e922e99:1909966</guid><dc:creator>CarlosAg</dc:creator><slash:comments>0</slash:comments><comments>http://forums.iis.net/thread/1909966.aspx</comments><wfw:commentRss>http://forums.iis.net/commentrss.aspx?SectionID=1046&amp;PostID=1909966</wfw:commentRss><description>&lt;p&gt;&lt;font color="#2b91af" size="2"&gt;&lt;font color="#2b91af" size="2"&gt;&lt;font color="#000000"&gt;I just saw the problem right after posting it :), we are doing this in AppHost, but it should be in root web.config&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font color="#2b91af" size="2"&gt;&lt;font color="#2b91af" size="2"&gt;Configuration&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; rootConfig = mgr.GetWebConfiguration(null);&lt;br /&gt;&lt;/font&gt;&lt;font color="#2b91af" size="2"&gt;&lt;font color="#2b91af" size="2"&gt;ConfigurationSection&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; section = rootConfig.GetSection(&lt;/font&gt;&lt;font color="#a31515" size="2"&gt;&lt;font color="#a31515" size="2"&gt;&amp;quot;system.web/globalization&amp;quot;&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt;, s);&lt;br /&gt;section.OverrideMode = &lt;/font&gt;&lt;font color="#2b91af" size="2"&gt;&lt;font color="#2b91af" size="2"&gt;OverrideMode&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt;.Allow;&lt;br /&gt;&lt;/font&gt;&lt;font size="2"&gt;mgr.CommitChanges();&lt;br /&gt;&lt;/p&gt;&lt;/font&gt;
&lt;p&gt;&lt;font size="2"&gt;Is that not the case?&lt;/font&gt;&lt;/p&gt;</description></item><item><title>Re: section.OverrideMode = OverrideMode.Allow; ----&gt; "The request is not supported"</title><link>http://forums.iis.net/thread/1909965.aspx</link><pubDate>Fri, 10 Jul 2009 21:35:45 GMT</pubDate><guid isPermaLink="false">50bcf3b4-f6fe-4638-adff-0c150e922e99:1909965</guid><dc:creator>CarlosAg</dc:creator><slash:comments>0</slash:comments><comments>http://forums.iis.net/thread/1909965.aspx</comments><wfw:commentRss>http://forums.iis.net/commentrss.aspx?SectionID=1046&amp;PostID=1909965</wfw:commentRss><description>&lt;p&gt;Your code above should work:&lt;/p&gt;
&lt;p&gt;&lt;font color="#2b91af" size="2"&gt;&lt;font color="#2b91af" size="2"&gt;Configuration&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; appHostConfig = mgr.GetApplicationHostConfiguration();&lt;br /&gt;&lt;/font&gt;&lt;font color="#2b91af" size="2"&gt;&lt;font color="#2b91af" size="2"&gt;ConfigurationSection&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; section = appHostConfig.GetSection(&lt;/font&gt;&lt;font color="#a31515" size="2"&gt;&lt;font color="#a31515" size="2"&gt;&amp;quot;system.web/globalization&amp;quot;&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt;, s);&lt;br /&gt;section.OverrideMode = &lt;/font&gt;&lt;font color="#2b91af" size="2"&gt;&lt;font color="#2b91af" size="2"&gt;OverrideMode&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt;.Allow;&lt;br /&gt;&lt;/font&gt;&lt;font size="2"&gt;mgr.CommitChanges();&lt;br /&gt;&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font size="2"&gt;Is that not the case?&lt;/p&gt;&lt;/font&gt;</description></item><item><title>Re: section.OverrideMode = OverrideMode.Allow; ----&gt; "The request is not supported"</title><link>http://forums.iis.net/thread/1909864.aspx</link><pubDate>Fri, 10 Jul 2009 12:51:28 GMT</pubDate><guid isPermaLink="false">50bcf3b4-f6fe-4638-adff-0c150e922e99:1909864</guid><dc:creator>diegochb</dc:creator><slash:comments>0</slash:comments><comments>http://forums.iis.net/thread/1909864.aspx</comments><wfw:commentRss>http://forums.iis.net/commentrss.aspx?SectionID=1046&amp;PostID=1909864</wfw:commentRss><description>&lt;p&gt;What would be the way to do&lt;/p&gt;
&lt;p&gt;%systemroot%\system32\inetsrv\AppCmd lock config &amp;quot;sitename&amp;quot; /section:system.web/globalization /commit:machine&lt;/p&gt;
&lt;p&gt;With C#? Basically my concern is the /commit:machine to ensure it does it at the applicationHost.config at least....&lt;/p&gt;
&lt;p&gt;Thank you&lt;/p&gt;</description></item><item><title>section.OverrideMode = OverrideMode.Allow; ----&gt; "The request is not supported"</title><link>http://forums.iis.net/thread/1909495.aspx</link><pubDate>Tue, 07 Jul 2009 18:47:28 GMT</pubDate><guid isPermaLink="false">50bcf3b4-f6fe-4638-adff-0c150e922e99:1909495</guid><dc:creator>diegochb</dc:creator><slash:comments>0</slash:comments><comments>http://forums.iis.net/thread/1909495.aspx</comments><wfw:commentRss>http://forums.iis.net/commentrss.aspx?SectionID=1046&amp;PostID=1909495</wfw:commentRss><description>&lt;p&gt;ErrorCode: -2147024846&lt;br /&gt;Source: &amp;quot;Microsoft.Web.Administration&amp;quot;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;Code: (s is the location/IIS7 site name)&lt;br /&gt;&lt;br /&gt;&lt;font color="#2b91af" size="2"&gt;&lt;font color="#2b91af" size="2"&gt;Configuration&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; config = mgr.GetWebConfiguration(s);&lt;br /&gt;&lt;/font&gt;&lt;font color="#2b91af" size="2"&gt;&lt;font color="#2b91af" size="2"&gt;Configuration&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; appHostConfig = mgr.GetApplicationHostConfiguration();&lt;br /&gt;&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;if&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; (chbSetting1.Checked)&lt;br /&gt;{&lt;br /&gt;&lt;/font&gt;&lt;font color="#2b91af" size="2"&gt;&lt;font color="#2b91af" size="2"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; ConfigurationSection&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; section = appHostConfig.GetSection(&lt;/font&gt;&lt;font color="#a31515" size="2"&gt;&lt;font color="#a31515" size="2"&gt;&amp;quot;system.web/globalization&amp;quot;&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt;, s);&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; section.OverrideMode = &lt;/font&gt;&lt;font color="#2b91af" size="2"&gt;&lt;font color="#2b91af" size="2"&gt;OverrideMode&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt;.Allow;&lt;br /&gt;&lt;/font&gt;&lt;font size="2"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; mgr.CommitChanges();&lt;br /&gt;}&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;Is there another way to allow the override mode of a section?&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;</description></item></channel></rss>