I inherited a project with a giant table in an aspx page that has a TON of inline code. Now I need to conditionally style a row based on the value of a textbox in the table. Unfortunately, I can't add a "runat=Server" tag to the table row because of all the embedded <% %> tags. I just need to apply the style to this row. I know all this embedded stuff needs to move to the code behind. I didn't write this - I just need to get this one small thing fixed.
<ajax:Accordion ID="Accordion1" runat="server" FadeTransitions="False"
SelectedIndex="0" HeaderCssClass="accordionHeader" ContentCssClass="accordionContent">
<HeaderTemplate>
<div style="height:20px;"> </div>
<table class="cart" >
<tbody>
<ItemTemplate>
<tr class="row I need to style " >
<%if (Isvalid) { %>.... tons more tags like this in the td sections.
After walking away for a bit, I tried putting an asp panel around it and then setting visibility of the panel in the code behind. Working perfectly now. Accepting switch because that would have worked as well.