IR Framework

Section.sort Method

The sort method modifies the sort order of a Results or Table.
object.sort (columnName, [order])

Arguments

object
Required. A Results or Table object.

columnName
Required. A string containing the name of the column on which to sort.

order
Optional. An integer indicating the sort order for this column. 1 = ascending, 2 = descending. If ommitted, the default value of 1 is used.


Remarks

The specified column is added to beginning of the sort list. If the column is already in the sort list, it is moved to the beginning.

Example:
//	Change the sort of a Result to sort primarily by the specified column.
ActiveDocument.Sections["R-MyResults"].sort("myColumn");


Requirements

ActiveDocument.loadObjectMethods() must be called after the Result/Table is created.