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
What are server-side comments in ASP.NET?
Can we have multiple worker process in an ASP.NET application? If so then how it has been handled by application? And who handles it?
Describe a Windows Service and its lifecycle ?
What is the difference between rest and restful?
Which namespace is used by ado.net?
What are sessions used for?
What are the different types of validation controls in asp.net?
Explain about the .NET framework?
What is asp net theme?
Explain security types in asp.net?
What is the significance of attaching a profile while creating a user?
How do you declare static variable?
Why do we use web config?
Explain the difference between an exe and a dll?
Explain what does mvc represent in asp.net? : asp.net mvc