2 children objects have different edit level issue

2 children objects have different edit level issue

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

fredg posted on Thursday, December 22, 2011

Hi, my root object has 2 children objects. When running the application, the 2 children have 2 diffrent edit level, i.e. 1 and 2. What causes the issue? How to fix it?   Thanks in advance.

RockfordLhotka replied on Friday, December 23, 2011

There is no simple answer. This is almost certainly caused by the way you are using data binding, because data binding automatically elevates the edit levels of objects as they become current.

You at least need to tell us the UI technology you are using, and within that UI technology you need to describe how you are using data binding, and whether you are using any helper objects to manage data binding, currency, MVVM, MVP, etc.

fredg replied on Friday, December 23, 2011

Sorry i did not provide more detailed info. The UI is windows form, and i use datagridview to bind collection and use textbox/combobox for a single object. Sometimes even different item in the collection have different edit levels. e.g. the root has edit level 0, one child has 1, another has 2.

After I modified code of databind/unbind, everything is fine now. Yes, when developing the UI, we have to restrictly comply the pattern.

I have enough material for the BO, but i don't find many for the CSLA.NET UI pattern/sample. Where can I find those material, including book and sample code?  Thanks and merry Christmas.


Copyright (c) Marimer LLC