views:

816

answers:

0

I am building a web-enabled ASP.NET 3.5 application in Visual Studio 2008 using C#. I am connecting to an SQL database.

The user must be able to insert, edit and delete entries from the database using the forms I create.

I am creating the screens and I ran into quite a snag. There is a table that contains many different types of fields: labels, textboxes, drop down lists, dates, times and files. I need to have an "Add New Task" button that will add a new row with the exact same format that also populates with an automatically incremented system generated primary key. Further, I need to have another button “Add New Item” which adds another row (with different formatting) as child to the task.

How do I code the "Add New Task" button to make it add a new row with the correctly formatted, pre-populated data, and further how do I code the “Add New Item” button that will appear as child to task?

Thanks so much in advance ...