In previous versions of WebDataGrid, if AutoCRUD=false was set, then all the editing could be handled manually. With this current version, the WebDataGrid attempts to lookup all the changed rows by key during a postback even when AutoCRUD=false. If the Grid isn't reloaded at the beginning of the postback or if any of the rows no longer exist an exception occurs: Requested record cannot be found by key. (Infragistics.Web.UI.GridControls.MissingRecordException).
In my web application, the edits are performed first to multiple rows and then the grid is reloaded at the end. Loading it at the beginning too would hurt performance, but the more important problem is that if any of the rows are removed by one user while another user is editing the grid (this is very likely) an exception will occur if the WebDataGrid looks for the missing rows instead of allowing the custom code to handle the updating.
Is there some property other than AutoCRUD that needs to be set for this version to disable the automatic row updating in the WebDataGrid?
I'm having the same trouble as well. Honestly, I can't figure out how to make the grid work properly with a collection. If I do row updating via AutoCRUD the server-side event doesn't allow me to change screen data. If I turn off AutoCRUD and handle the update via an ASP update button then I get the MissingRecordException. What am I missing?
Hi,
I have the same exception. I have a grid with 6000 records in it, I use paging with 500 rows.If I edit a row on the first page, and then go to the next page it works fine. But when I go to the eleventh page and change a row there and then go back to one of the first pages I get this exception:[MissingRecordException]: Requested record cannot be found by key.
-I bind my Grid to a generic list which is in a business object I store that in a session.-AutoCrud is on. - I've already tried EnableViewState and EnableDataViewState.
if (Session["TemplateSet"] == null) { TemplateSet = new BillingAllocationSet(); TemplateSet.Fill(6000); // fills the generic list with test data Session["TemplateSet"] = TemplateSet; } else { TemplateSet = Session["TemplateSet"] as BillingAllocationSet; }This is how i bind it. private void BindToGrid() { TemplateGrid.ClearDataSource(); TemplateGrid.DataSource = TemplateSet.BillingAllocationSetItems; TemplateGrid.DataBind(); }
Any suggestions?Regards,
Balazs