User Tools

Site Tools


resetsort_apply_sort_order_to_browse_.htm
Navigation:  ABC Library Reference > BrowseClass > BrowseClass Methods >====== ResetSort (apply sort order to browse) C6H0009.jpg ====== Previous pageReturn to chapter overviewNext page

ResetSort( force ), VIRTUAL, PROC

blk2blue.jpg

ResetSort Reapplies the active sort order to the browse list.
force A numeric constant, variable, EQUATE, or expression that indicates whether to reset the browse conditionally or unconditionally. A value of one (1 or True) unconditionally resets the browse; a value of zero (0 or False) only resets the browse as circumstances require (sort order changed, reset fields changed, first loading, etc.).

The ResetSort method reapplies the active sort order to the browse list and returns one (1) if the sort order changed; it returns zero (0) if the order did not change. Any range limits, locators, or reset fields associated with the sort order are enabled.

TipBox.jpg

Use ResetSort followed by UpdateWindow to refresh and redisplay your ABC BrowseBoxes. Or, use the WindowManager.Reset method.

Implementation:

The ResetSort method calls the SetSort method to apply the current sort order. The ABC Templates override the ResetSort method to apply the sort order based on the selected tab.

Return Data Type:     BYTE

Example:

BRW1.ResetSort FUNCTION(BYTE Force)       !apply appropriate sort order

CODE

IF CHOICE(?CurrentTab) = 1               !If 1st tab selected

 RETURN SELF.SetSort(1,Force)            !apply first sort order

ELSE                                     !otherwise

 RETURN SELF.SetSort(2,Force)            !apply second sort order

END

See Also:     AddRange, AddResetField, AddSortOrder, Set Sort ,UpdateWindow

resetsort_apply_sort_order_to_browse_.htm.txt · Last modified: 2021/04/15 15:57 by 127.0.0.1