60
get accessor of the enumerable field within a field layout being called without expanding
posted

Hi,

I have a XamDataGrid field layout with two IEnumerable fields within it. with in the get accessor of both the enumerable fields, I make a external call to populate the data for each and return back.

The behavior for this setup used to be like this: the parent row shows a expander, and when expanded the get accessor gets called and retrieves the rows to show for both the enumerable fields.

We have this setup from long time and is working fine as above. But recently, for some users the get accessor is getting called before even expanding, which is not the case for me when I debug locally. So, the same code is behaving differently for different users. When I compared the dlls that are loaded in mine with theirs, I see these two additional in mine: PresentationFramework-SystemCore.dll, System.ComponentModel.DataAnnotations.dll

Do they have anything to do with this behavior?

Why do I see different behavior for different users?

Also, theoretically I expected get accessor of enumberable to be called when loading parent field layout without expanding, but that was not the case how its happening (is it some optimization in infragistics?)

Our parent field layout itself is an enumerable list of model items, so as the external calls are happening for all the rows at once, UI crashes due to OOM. This was never the case before.

Any alternative approaches that I can take so that I can trigger the external call only when expanded, and prevent the list being populated all beforehand?

Application is using Infragistics 16.1 and is targeted towards .net framework 4.0. However, .4.6.1 is installed on the users' machines. I suppose there is backwards compatibility, so this shouldn't be a issue, right?

Thanks.