Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
130
FieldLayoutSettings for Child Object
posted

Question.

How do I set the field layout for child objects?

I have bound a hierarchical object collection to the grid.  Organisations > Contacts.  This worked as expected with contacts appearing under the organisation and the ability to exand and contract.

The next step though was to setup the columns as I wanted. So I set the AutoGenerateFields and manually set the fields i want.  Again this worked but now I do not have the contacts below the organisations. 

<igDP:FieldLayout >
                    <igDP:FieldLayout >
                    <igDP:FieldLayout.Fields>
                        <igDP:Field  Name="Organisation" Label="Organisation" IsExpandable="False" IsPrimary="true" Row="0" />
                    </igDP:FieldLayout.Fields>
                </igDP:FieldLayout>
      ...

Parents
  • 69686
    posted

    Hello,

    There are several ways that I can think of to achieve this.

    1. Set the IsNestedDataDisplayEnabled property of the XamDataGrid to false

    2. Set the ExpansionIndicatorDisplayMode property of the FieldLayoutSettings to Never

    3. Remove the second FieldLayout from the FieldLayouts collection

    4. Cancel the RecordExpanding event (e.Cancel = true;)

Reply Children
No Data