dynamically change stylesheet C#
<p>I want to change the style sheet of a group of controls on the selected index change of a dropdown.</p>

<pre><code>  &lt;asp:PlaceHolder ID="plcPreview" runat="server"&gt;
&lt;asp:DropDownList ID="ddlTest" runat="server" &gt;
&lt;asp:ListItem Text="Test1"&gt;&lt;/asp:ListItem&gt;
&lt;asp:ListItem Text="Test2"&gt;&lt;/asp:ListItem&gt;
&lt;/asp:DropDownList&gt;

&lt;asp:TextBox ID="txtTest" runat="server"&gt;&lt;/asp:TextBox&gt;&lt;br /&gt;

&lt;ajax:ComboBox ID="cmbTest" runat="server" DropDownStyle="DropDownList" AccessKey="f"  Width="325" Height="20"
AutoCompleteMode="SuggestAppend" CaseSensitive="False" ItemInsertLocation="OrdinalText" style="margin-left:-3px;" TabIndex="3"&gt; 
&lt;asp:ListItem Text="Test1"&gt;&lt;/asp:ListItem&gt;
&lt;asp:ListItem Text="Test2"&gt;&lt;/asp:ListItem&gt;
&lt;/ajax:ComboBox&gt;&lt;br /&gt;
&lt;div class="gridmain"&gt;

&lt;asp:GridView ID="grvTest" runat="server" AutoGenerateColumns="true"
ShowHeader="True" CssClass="tabledata" Width="100%" &gt;
&lt;AlternatingRowStyle CssClass="pointer"  /&gt;
&lt;RowStyle CssClass="even pointer" /&gt;
&lt;HeaderStyle CssClass="headings" /&gt;
&lt;/asp:GridView&gt;
&lt;/div&gt;
&lt;/asp:PlaceHolder&gt; 
</code></pre>

<p>I want to apply different stylesheet only to this placeholder and not to the entire page depending on the value selected in the dropdown.</p>

<p>I am using this in the code behind</p>

<pre><code>                HtmlLink css = new HtmlLink();
                css.Href = "themes/" + theme + "/css/default.css";
                css.Attributes["rel"] = "stylesheet";
                css.Attributes["type"] = "text/css";
                plcPreview.Controls.Add(css);
</code></pre>

<p>But the stylesheet gets applied to the entire page. I want it to be applied only to the placeholder and not to the entire page.</p>

<p>Thanks,</p>
