Intersoft Support Center

Sort Self-Referencing Child Data

WebGrid introduces a new setting in SelfReferenceSettings object called ApplyChildSorting. This feature instructs WebGrid to perform sorting on the self referencing child when the column sorting action occurred.

In this topic, you will learn how to sort Self-Referencing Child data.

To sort Self-Referencing Child data

  1. Create Self-Reference WebGrid.
  2. Open WebGrid Designer and go to Advanced tab.
  3. Select RootTable and click See all properties.
  4. Expand SelfReferencingSettings and set ApplyChildSorting to True.
  5. Expand RootTable and Select SortColumns.
  6. Add a column and set ColumnMember to EmployeeID and SortOrder to Ascending.
  7. Run the project.
Previous Next