Trouble getting a FormView to update with a Dataset datasource

I have a Formview control that is databound to a dataset. When I click on the "Update" button, it appears that there is no way to access the bound data or I'm just not seeing it. I am handling the _ItemUpdating event. Given my control name is FormView1, how can I get to the databound fields and their data?

I have an Order Entry form with an Order Entry Header table and an Order Details table. The user adds a new header record by filling in some textboxes and hitting "Save", creating the Order Header record and returning an Order ID. This is the related key to the Order Details table. Since there is no data in the Order Details table at this time, I could not get a FormView or GridView to populate. Messing around with the EmptyDataTemplate for both didn't work out at all (ex. The FormView would show the fields, but when I hit "Edit", it did nothing.) So I decided to do things "manually"; create a blank record in a dataset and use it as the Datasource for the Formview. This worked OK. I could even edit the record. Now, when I hit "Update" to commit my changes, I want to be able to pull the data from the FormView dataset and commit them to the SQL database. Sounds cludgy, but it was very frustrating. So that's the long answer to your short question, unless you have a better idea........................... Thanks!

You could put a defalut record in the Order Details table that has a ID of 1 lets say. You could populate that table with some thing like "No details available yet" Then when you create the first new header you can manually put in the default ID of 1 then you can chech to see if the ID = 1 on a edit and if it does then created a new record and replace the FK with the correct ID.

A long time ago (May 2011), I have written an article showing you how to create a DLL using Visual Studio 2005 to be hosted in SQL Server 2005. That was valid at that time and it is still valid if you are still using these versions. You can still re…

It was really hard time for me to get the understanding of Delegates in C#. I went through many websites and articles but I found them very clumsy. After going through those sites, I noted down the points in a easy way so here I am sharing that unde…

Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…