Hi
I have some questions regarding FieldLayout:
- Do all defined FieldLayouts get initialized?
- Assuming the answer to my first question is no, meaning only used FieldLayouts get initialized, if i switch from one FieldLayout to another, does the old one gets automatically de-initialized?
- Assuming the answer to my first question is yes, how can i know which ones are in used?
- Last but not least if i have multiple layouts defined for parent and child records, how can i get the active top level / root FieldLayout?
Hello Marco,
I have been looking into your issue and was wondering if you could describe in more details what you mean since I am not sure what you mean “new” and “old” layouts and “multiple layouts defined for parent and child records”. Please describe your project in more details so I can get an overall understanding of your scenario.
Looking forward to hearing from you.
Sincerely,
Petar Monov
Developer Support Engineer
Infragistics Bulgaria
www.infragistics.com/support
Hi Petar
What i meant with new and old layout is, when switching from one FieldLayout (old or FL1) to another (new or FL2), does the old or FL1 gets automatically de-initialized?
And regarding multiple FieldLayout, if i understand correctly the datagrid searches for the approriate FieldLayout in the FieldLayouts collection during initialization. Eg. I defined 3 FieldLayouts (CustomerFL, OrderFL, OrderDetailFL) and load a hierarchiral data (Customer -> Order -> OrderDetail), how can i get the top / root FieldLayout (CustomerFL in the example)? In my project several FieldLayouts get defined for the datagrid and the data is only known at runtime.
Hello,
I am just checking the progress of this issue and was wondering if you managed to achieve your goal or if you need any further assistance on the matter.
If the above suggestion helped you solve your issue please verify the thread as answered so other users may take better advantage of it.
Sincerely,Petar MonovDeveloper Support EngineerInfragistics Bulgariawww.infragistics.com/support
Hi,
In the XamDataGrid there is a FieldLayouts collection and by default the first level of data gets FieldLayouts[0], the second
FieldLayouts[1] etc. Also you can define keys for your FieldLayouts and handle events like FieldLayoutInitialized and FieldLayoutInitializing. If a FieldLayout is removed from the collection it should get disposed.
Hope this helps. Let me know if I have misunderstood your question and if I can assist you further on the matter.