I'd like to have X number of Ajax panels on my list page which is inside a master Page for site consistency.
The tutorials I'm coming across on ASP.NET Ajax seem to imply I need a <form><asp:ScriptManager ID="asm" runat="server"/></form>
around my <table></table>
layout. I would think for this function (each code being an individual Ajax element) that each <tr></tr>
would be a form unto itself. So that actions specific to a code only trigger an Ajax Async postback of that piece. Here's what I imagine the proper layout would look like:
<table>
<thead>
<tr>
<th>
Code
</th>
<th>
Description
</th>
<th>
Document
</th>
<th>
Customer Contact Required for Resolution
</th>
<th>
Associate
</th>
<th>
Shareholder
</th>
<th>
Customer
</th>
<th>
Regulatory
</th>
<th>
Root Cause
</th>
<th>
Investor Requirements
</th>
</tr>
</thead>
<tbody>
<% foreach (var item in GetCodes())
{ %>
<tr>
<form><asp:ScriptManager ID="asm" runat="server"/>
<asp:UpdatePanel runat="server">
<td><%=item.Code %></td><td>item.Description</td><td><%=item.Document %></td>
<td><asp:ListBox ID="lbAssociate" /></td>
<td><asp:ListBox ID="lbShareholder" /></td>
<td><asp:ListBox ID="lbCustomer" /></td>
<td><asp:ListBox ID="lbRegulatory" /></td>
<td><asp:dropdownlist ID="ddlRoot" /></td>
<td><asp:CheckBox
ID="_ckbAllInvestorRequirements"
runat="server"
Text="All"
onclick="AllInvestorClicked()" />
<asp:CheckBoxList
ID="_cblInvestorRequirements"
runat="server">
</asp:CheckBoxList></td>
<td><asp:Button ID="Submit" Text="Submit" runat="server" /></td>
</asp:UpdatePanel>
</form>
</tr>
<% } %>
</tbody>
</table>
Is this the proper layout for iterative Ajax mini-forms? It appears XHTML doesn't like the idea of a <table>
having <form>
inside it so how could I lay this out? I would think wrapping the whole table in a form would result in all the items being reloaded on each request instead of a single line item.