What I created is an production schedule report.
I have a PlaceHolder control that is programmatically filled with an HTML table with a textbox and a SELECT (dropdown) box for each record. Now how do I iterate through each textbox and dropdown so that I can update the records to my database (SQL Server).
Here is what the table looks like:
GROUPBYHEADER (cell spans width of table)
RecordID Hours Description Textbox DropDown
Then on this line I have a more information about this record (cell spans width of table).
RecordID Hours Description Textbox DropDown
Then on this line I have a more information about this record (cell spans width of table).
RecordID Hours Description Textbox DropDown
Then on this line I have a more information about this record (cell spans width of table).
Total Hours Here
GROUPBYHEADER (cell spans width of table)
RecordID Hours Description Textbox DropDown
Then on this line I have a more information about this record (cell spans width of table).
RecordID Hours Description Textbox DropDown
Then on this line I have a more information about this record (cell spans width of table).
RecordID Hours Description Textbox DropDown
Then on this line I have a more information about this record (cell spans width of table).
Total Hours Here
Should I scrap my 2-days of work and use a ASP.Net control or stick with the standard HTML controls that I've already done, if so then I need to know how to iterate through each textbox and Select dropdown.
By the way the textbox and select dropdown names have names like:
name="textbox[RecordID]"
I've been able to iterate through controls named like this in ASP and PHP, but I've never done it in ASP.Net.
I would prefer any examples in C#, but I can usually translate VB.Net.
Start Free Trial