Creating ascending or descending sorts in a report

You have a hyperblock in a report and want users to be able to sort its contents in ascending or descending order by selecting Ascending or Descending from a combo box.

  1. Create a custom hierarchy.
    Right-click Custom Hierarchies in the Accessories pane and select New Custom Hierarchy.
  2. Right-click the hierarchy and select Edit.
  3. Add a parent node and name it Ascending.
  4. Add a sibling node and name it Descending.
  5. Click the Show Unique Names icon.
    node and node2 are displayed. These are the unique names of the nodes.
  6. Select node and press <F2> to make it editable. Rename it ASC.
    Note: Unique names are case-sensitive: "Asc" will not work.
  7. Rename node2 as DESC.
    Note: Unique names are case-sensitive. "Desc" will not work.
  8. Create a combo box in a report and drag the custom hierarchy onto it. The combo box displays Ascending and Descending.
  9. Create a hyperblock from a dimension. Select the hyperblock and select Sorting in the List Designer.
  10. Click New Sorting Criterion.
  11. In Sorting Criteria Settings, select Caption as the type.
  12. Select <Edit Formula> as the Order.
    The Edit Formula dialog box is displayed.
  13. In the Edit Formula dialog box, expand Listviews and double-click the name of the combo box which contains the custom hierarchy. This is then displayed in the right-hand pane (for example, =ReportObjects.ListView3.text).
  14. Click OK.
  15. In List Designer, save the changes to the list.
  16. View the report in View Mode.
  17. Select 'Ascending’ or 'Descending’ from the combo-box to change the order of the elements in the hyperblock.