Rowupdating

Posted by / 15-Dec-2017 22:12

Rowupdating

Something that has been said many times, but needs constant repeating until every developer is aware of its importance, is the performance difference between row-by-row updating and bulk updating. Let me ask this differently: The best way to find out is to benchmark.

Again, the benchmark code is available from a gist, and I will paste it to the end of this blog post as well.

When we edit a row in our Grid View and press the “Update” button, at some time it’s received in the Row Updating method.

But as I noted in the comments in that method, some collections that should contain the columns (names, old values and new values) are always empty. And the Row Updated method is never even touched!!! NET Forums that I need to use a Data Source control.

Which means I won’t make my 70% code reduction Microsoft has always promised me.

event is raised when a button is clicked in the Grid View control.

rowupdating-27rowupdating-62rowupdating-33

This does save a lot of time on the network and all the layers in between.

One thought on “rowupdating”