Although I appreciate your offer to help, I couldn't understand/implement either of the suggested solutions.
Since I couldn't get the datalist to work, I found an alternate approach to organize the display of dynamic controls into a page.
To keep it simple, I used a placeholder(ph1) in the html and I did this in the page_load code:
------------------------------------------------------
ph1.Controls.Add (New LiteralControl("<table>"))
For each oItem in arrMyControlList
ph1.Controls.Add (New LiteralControl("<tr><td>"))
ph1.Controls.Add( oItem.A)
ph1.Controls.Add (New LiteralControl("</td><td>"))
ph1.Controls.Add( oItem.B )
ph1.Controls.Add (New LiteralControl("</td></tr>"))
Next
ph1.Controls.Add (New LiteralControl("</table>"))
-----------------------------------------------------
it works.
"Jon Paal" <Jon[ nospam ]Paal @ everywhere dot com> wrote in message news:up**************@TK2MSFTNGP12.phx.gbl...
how do I load controls to the templates for the DataList control.
<asp:datalist id="dl1" runat="server" >
<ItemTemplate>
" how to load control(s) here ????"
</ItemTemplate>
</asp:datalist>