StyM
January 29th, 2004, 02:13 AM
hello and Good Day.
may i know, how i can create controls dynamically?
i have a sample code below but just wont work.
where as in jsp this technique would work, but dont know how to do it asp.net
<form id="Form1" action="Body.aspx" method="post" runat="server">
<FONT face="MS UI Gothic"></FONT>
<% for ( int iCounter = 0 ; iCounter < 10 ; iCounter++ ) {
string strName = "employeeid" + iCounter.ToString();
%>
<asp:textbox id=<%strName;%> style="Z-INDEX: 101; LEFT: 248px; POSITION: absolute; TOP: 72px" runat="server" Width="248px" Height="24px">
</asp:textbox>
<% } %>
</form>
can somebody please help me.
thanks for the help.
may i know, how i can create controls dynamically?
i have a sample code below but just wont work.
where as in jsp this technique would work, but dont know how to do it asp.net
<form id="Form1" action="Body.aspx" method="post" runat="server">
<FONT face="MS UI Gothic"></FONT>
<% for ( int iCounter = 0 ; iCounter < 10 ; iCounter++ ) {
string strName = "employeeid" + iCounter.ToString();
%>
<asp:textbox id=<%strName;%> style="Z-INDEX: 101; LEFT: 248px; POSITION: absolute; TOP: 72px" runat="server" Width="248px" Height="24px">
</asp:textbox>
<% } %>
</form>
can somebody please help me.
thanks for the help.