I am working with a webpage and I will connect the data i have to a data base. so my question how can I create different number of labelsand assigning values or data to them and not loss them? I working on a web page and i have placeholders for the new labels but i have no idea how to keep them there and assign value to them in order to save them in the database.and the following is part of my code and i put placeholder to create more labels in the execution time.
<tr>
<td style="text-align:right"><b><br /><br />
<asp:Label ID="lblAudioLabel" runat="server">Audio:</asp:Label>
<br /><br /></b>
</td>
<td><br /><br />
<asp:Label ID="lblPrimary" runat="server"></asp:Label>
<br />
<asp:PlaceHolder ID="placeHolderAudio" runat="server" /><br />
</td>
</tr>
The numbers I need to add will vary every time. So, Im thinking to add a new number every time that i have more than one number in the placeHolder. Im new to ASP so any help will a lot for me.
I would suggest using a built-in ASP.NET data-binding control rather than the placeholder method.
Here is a good tutorial explaining the basics of databinding in ASP.NET. It is older, from 2004, but still very applicable.
Mastering ASP.NET DataBinding
HTH