This is a migrated thread and some comments may be shown as answers.

How to invoke "update" on an edited item? ...Or?

1 Answer 50 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Mike Bridge
Top achievements
Rank 1
Mike Bridge asked on 04 Apr 2011, 08:55 PM
Hi-

I have all my grid items in editmode, and I'd like to know how to apply changes to an InsertedItem when someone clicks on "OK" somewhere else in the page.  Right now I'm doing a loop over these to get the rest of the items:

foreach (GridDataItem item in radGrid.Items)
{
   // do something with the items
}

But when I am inserting a new item I'm not getting access to it.   Should I manually invoke "Update" from code-behind as part of the page submit event (and how can I do that?), or should I try to somehow read the new values in the controls for the InsertItem without invoking an "update"?

Thanks,

-Mike

1 Answer, 1 is accepted

Sort by
0
Mike Bridge
Top achievements
Rank 1
answered on 04 Apr 2011, 09:30 PM
Sorry, figured this out.  I wasn't calling it from the submit event.  It seems to be updating my data structure correctly when I move the code there.
Tags
Grid
Asked by
Mike Bridge
Top achievements
Rank 1
Answers by
Mike Bridge
Top achievements
Rank 1
Share this question
or