EUG PD


Viewsort

 
Published in EUG #5

This program, written by David Atherton of BBC Acorn User, can be used to sort lists, tables or any other data within the View word processor. As, when RUN, it creates a machine code program (and therefore the disk in the drive needs to be write-enabled), it hasn't been included as a self-running program from the main menu. Instead, access it by typing LOAD"U.5SORTSr" at the prompt. Insert your own write enabled disk before RUNning it.

You will then be prompted to "press any key". Do so and a program called VSORT will be saved. Keep VSORT on your disks alongside your text files.

To use the program, mark the area of text with MK1 & 2 (1 at the top, 2 at the bottom) and type *VSORT from the Command Screen. The display will show the word "Sorting" following by an increasing number of dots to show the progress.

If no markers are set, then the entire text will be sorted. Each line will be treated as an entry with blank lines being sorted to the top of the list and lines with embedded commands placed at the bottom.

For example: Screen before sort:

..*..*..*..*..<
Bloggs, J
Smith, D
Jones, H
Walker, D
Another, A, N

becomes this screen after sort:

..*..*..*..*..<
Another, A, N
Bloggs, J
Jones, H
Smith, D
Walker, D

Will Watts, EUG #5

David Atherton