DynamicBindingListBase SaveItem (4.5.600)

DynamicBindingListBase SaveItem (4.5.600)

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

BlueScreen posted on Tuesday, July 15, 2014


we are currently refactoring our client application to a SOA (ASP.NET MVC, Web Service, new HTTP Channel)

We make use of DynamicBindingListBase, but it does not support async save.

Is this intended, what should be do?


Thanks in advance


RockfordLhotka replied on Tuesday, July 15, 2014

DynamicBindingListBase exists for one purpose: to create a collection that can be bound to a datagrid control in a smart client application (like WPF).

For all other purposes you should use BusinessListBase.

BlueScreen replied on Tuesday, July 15, 2014

Hi Rocky,


thats exactly what we do. We use most lists for trees (which are some kind of grids) in WinForms.

The point is we save each item on it's own, with SaveItem(item). But now that we have to do everything in an async way, we can not do that.

I created a work around by overriding the SaveItem(index) method and changed the Save on the Savable object to SaveAsync, which is working perfectly fine.

I am just wondering why the list does not support that by default like the BusinessBindingList (of course, we use that one too, but for other purposes and use cases).



RockfordLhotka replied on Tuesday, July 15, 2014

fwiw, if you look inside the code for the dynamic list implementation it is async. But because the save method is intended to be called by a datagrid's event handler indicating that the user moved focus off the row, the public interface to the save isn't "async".

BlueScreen replied on Wednesday, July 16, 2014

Hello again and thanks for your response,


the implementation of SaveItem() looks like this:

// do the save

result = (T)savable.Save();

I cant see how the implementation is async in any way. I must be missing something here.

Are you saying that there is no way to save in an async manner when using this type of list?

Does that mean I can not use the original at all when working with the new DataPortal http channel?



Copyright (c) Marimer LLC