|
Rank: Advanced Member Groups: Member
Joined: 6/14/2007 Posts: 83
|
Hi,
How should I go about posting back to the server each "Update" event to save the change one-by-one instead of enumerating the "Changed log"?
No matter what I do the _ItemChanged, _ItemAdded and _ItemDeleted events don't seem to fire.
Thanks
Steve Komaromi
Computer Systems Manager, Lead Developer Business Risk Partners, Inc. Tel: 1-(860)-903-0039
|
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,217
|
Hi,
Sorry about the delay. Somehow this message slipped through our queue. If you want to save the change one-by-one, you can use a ButtonColumn and then set the Grid's running mode to "Server". This way every time the button in the ButtonColumn is clicked, the Grid will post back right away and trigger the server side ItemCommand event. You can then handle everything in the Grid's ItemCommand event handler.
All server events depends on page posting back. So if your ItemChanged/ItemAdded/ItemDeleted are not fired, please check whether your page has been posted back first.
Thanks!
|
|
Rank: Advanced Member Groups: Member
Joined: 6/14/2007 Posts: 83
|
Thank you for coming back to me,
I did try setting the object to server mode, but it did not post back either. However when I posted, the three events, add, change and delete fired multiple times (as many records had that particular type of editing).
However, I decided to enumerate the three different type of editing to a data table and fetch it to my sql stored procedure to be processed as batch.
Thank you for your suggestion though.
Thanks
Steve Komaromi
Computer Systems Manager, Lead Developer Business Risk Partners, Inc. Tel: 1-(860)-903-0039
|
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,217
|
Hi,
Server mode only works with ButtonColumn. If you use EditCommandColumn/DeleteCommandColumn it will always be cached. However caching changes and then process it in batch is the preferred way because it reduces the number of post back needed thus improves performance.
Please feel free to let us know if you have any more questions.
Thanks!
|
|