SortDescription class

Build 1501 on 14/Nov/2017  This topic last edited on: 22/Mar/2016, at 16:37

Description

Defines a single sort within parent Sort in a SortList in a DirectoryStyle in a DirectoryStyleList  in a BaseQuery in the GN4ShellConfiguration in a xxx_config.xml file.

Members

PropertyNamefull path to the object, typically the same as the column that displays it.
IsAscendingfalse for Z-A or "newest on top" sorts, true for A-Z or "newest on bottom".

Example

<SortList>

  <Sort Name="Modified">

    <SortDescription PropertyName="[article.modifiedDate]" IsAscending="false" />

    <SortDescription PropertyName="[article.name]" IsAscending="true" />

  </Sort>

  <Sort Name="Name">

    <SortDescription PropertyName="[article.name]" IsAscending="true" />

  </Sort>

  <Sort Name="Length">

    <SortDescription PropertyName="[article.bodyTextH]" IsAscending="true" />

  </Sort>

  <Sort Name="Folder">

    <SortDescription PropertyName="[article.folderRef.path]" IsAscending="true"/>

    <SortDescription PropertyName="[article.name]" IsAscending="true"/>

  </Sort>

  <Sort Name="Workstate">

    <SortDescription PropertyName="[article.folderRef.workstateRef.name]" IsAscending="true"/>

    <SortDescription PropertyName="[article.name]" IsAscending="true"/>

  </Sort>

</SortList>

Multi-key sorts

You can specify more <SortDescription lines, one for each sort key.

An example:

<Sort Name="Folder">

  <SortDescription PropertyName="[article.folderRef.path]" IsAscending="true"/>

  <SortDescription PropertyName="[article.name]" IsAscending="true"/>

</Sort>

The above sorts first by folder, and within the folder, sorts by article name.