Undo in Root collection Roles

Undo in Root collection Roles

Old forum URL: forums.lhotka.net/forums/t/897.aspx


arquisoft posted on Monday, August 14, 2006

I had read the book Expert VB 2005 Business Objects and I realize that

in the example Project Tracker in the Roles administration is not possible make Undo after make some changes in Roles. How I can implement de Undo in this case ?

Thanks a lot.

Arquisoft from Chile

Tray replied on Tuesday, August 15, 2006

Arquisoft,

The Roles object in ProjectTracker is an editable collection containing Role editable objects (editable objects contained in an editable collection).

My understanding is that if you call CancelEdit on the collection, the call is passed down to each child object (Role) so that the child object takes care of its own editing. Note that the collection itself does not take the editing snapshots, only the child objects do.

With this in mind, if you call BeginEdit on the collection, make some changes to any one or more of the child objects and then call CancelEdit on the collection, the collection will pass the CancelEdit call to all of its child objects.

Can you be more specific with the situation that you are having trouble with?

Regards
Tray

Copyright (c) Marimer LLC