Sqldatasource updating event
after filtering) and now the user wants to edit the grid.
It's not possible because there's no other row which can be clicked to change the selection and save changes. For such a scenario, you just have to call the client side update() method of C1Grid View (on a button click) and it'll work.
Now you can ask questions directly to me on my new site ASPForums.
Net Question Answer site, specially started to allow visitors of this site ask their doubts and queries. Just click the Ask Now button and ask your question now.
All samples of course assume you’re doing everything in your page, but I have to do everything in my code-behind, because on forehand I don’t know what I’ll be binding to my Grid View.
But for this demo, I’ll show you the simple version, that also doesn’t work 🙂Let’s bind the data to our Grid View and have it autogenerate our columns, as well as an edit button.Many a times you wish to show data in a Grid View and allow users to edit the data and save it.It used to be a cumbersome and time-consuming task where you had to define template columns and then manually get the updated values.For example a Sql Data Source, which is automatically added to your Web Form if you drag-n-drop your way around Visual Studio 2005.
The problem is, I’d very much like to do so, if ASP. But I can’t set a Data Source property or anything on the Sql Data Source!!! I probably have to read the cells on the Grid View of the selected row, find the controls, get the values from those and insert those into my Data Set.
Today I was working on getting a row of the Grid View control to save the contents of a Drop Down List, and needed to add some custom code to set values passed to the Sql Data Source control on the update event.