Csla 3.5 - Root BO not notified of child collection changeCsla 3.5 - Root BO not notified of child collection change
Old forum URL: forums.lhotka.net/forums/t/5175.aspx
ajj3085 posted on Wednesday, July 30, 2008
Hi,
I have a child BO collection class off of a root BO. The root BO has a rule that says the collection can't be empty; for some reason the rule doesn't get run if I add something to the collection.
Any ideas?
Thanks
Andy
ajj3085 replied on Wednesday, July 30, 2008
Anyone know what's going on? I tired the old school wiring the event manually.. but in a remoting scenario FieldDataManager throws an InvalidOperationException when deserializing.
RockfordLhotka replied on Wednesday, July 30, 2008
How current are you?
3.5.1 RC0 has a bug fix which affects how events cascade up, because cascading a child event up as a PropertyChanged event was very bad for data binding.
So now it cascades a child event up as a ChildChanged event instead of PropertyChanged.
ajj3085 replied on Thursday, July 31, 2008
I'm on 3.5.0. So what's the best way for the root BO to "hear" the ListChanged event from the child BO BLB so I can run the rule?
ajj3085 replied on Thursday, July 31, 2008
Ok.. so I'm trying the RC to see how I can get this working. It looks like the root BO needs to subscribe to the ChildChanged event on the child BLB?
That seems a step backwards to me... 3.5 allowed me to remove code to handle wiring up events, and now that's what I have to do. Am I missing something?
Thanks
Andy
ajj3085 replied on Thursday, July 31, 2008
Nevermind.. I found the override for OnChildChanged. Ya!
Andy
Copyright (c) Marimer LLC