StrataFrame Forum

BO loses datasource in Custom property

http://forum.strataframe.net/Topic32936.aspx

By Andrew Harper - 4/16/2015

Hi,

 

I am wondering if anyone has seen the behaviour where a business object has lost its datasource in the get code for a custom property?

 

Using the debugger if I set a breakpoint in a fill method me.DataSourceKey contains the value set at form design time in the BO’s properties sheet. If I set a breakpoint in the Get code of a custom property, me.DataSourceKey is empty. This behaviour seems to relate to this specific form which is instantiated via reflection from a data driven menu system used by our application. I have checked the source code and can find no statements that change the BO.DataSource. Explicitly setting the BO datasource in the form load makes no difference to the behaviour.

 

I created a simple project consisting of a standard strataframe maintenance form using the BO in question from the same BO library and the BO datasource is set correctly in the Get code and everything works as expected. It is not feasible to post an example of the problem form due to the complexity of the form and its calling environment.

 

I have kludged a work around in the problem form but am interested in any thoughts or suggestions.

 

TIA

 

Andy