Suppose you display a data having 200 records in a
datagrid. Then you edit 100 records of them. Now when you
will press update button,all 100 records should be updated
in single shot rather than reading every record and
updating. How to do it?

Answer Posted / pradeep

Each row is having Edit/Update/Cancel button.
In "_UpdateCommand" event, we can write a code to update
directly into the database. But it is not good practice.
For updating whole records in a single event, we need to
have hidden column for updateflag and while updating we can
store the updated data into session. By using BUTTON
control out side of datagrid, we can find only 100 records
(updated records) based on updateflag and we can update
only those records into DB.

Is This Answer Correct ?    1 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

List the types of authentication supported by asp.net?

521


How to Insert/Add in ASPXgridview

561


What is full trust in asp.net?

535


What do you understand from custom control?

601


What is the sequence in which ASP.NET events are processed?

465






What is the difference between session object and application object?

583


What does the orientation property do in a menu control?

527


What is the difference between localization and globalization?

552


Is post back in asp.net?

512


What is autopost?

514


How do I create a web form?

524


what are the Custom controls in asp.net?

560


What is the flow of processing of the request? : asp.net mvc

503


How asp.net mvc differs from asp.net web forms? : asp.net mvc

537


What is the difference between Session and response.Redirect?

608