home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Fresh Fish 9
/
FreshFishVol9-CD2.bin
/
bbs
/
util
/
dosk-1.0.lha
/
DosK
/
Commands
/
SortK
< prev
next >
Wrap
Text File
|
1995-01-04
|
3KB
|
138 lines
FAILAT 21
SETENV COUNT 0
LAB START
ALIAS MV_K SYS:UTILITIES/MULTIVIEW
requestchoice >env:OPT "SortK ©DECEMBER 1994 By Kenneth J. McCormick. All Rights Reserved." "Select Option " "FILE" "DIR" "LIST" "SIZE" "CASE" "NUMERIC" "BYE"
IF $OPT EQ "0"
SKIP DONE
ENDIF
lab job
if $OPT eq "1"
REQUESTFILE >ENV:FILE1 TITLE="SORT FROM"
endif
if $opt eq "2"
REQUESTFILE >ENV:FILE1 TITLE="SORT FROM" DRAWERSONLY
CD $FILE1
endif
if $opt eq "3"
REQUESTFILE >ENV:FILE1 TITLE="SORT FROM" DRAWERSONLY
CD $FILE1
endif
if $opt eq "4"
REQUESTFILE >ENV:FILE1 TITLE="SORT FROM" DRAWERSONLY
CD $FILE1
endif
IF $OPT EQ "1"
COPY FROM $FILE1 TO RAM:TEMP_K2
SORT RAM:TEMP_K2 RAM:TEMP_K
MV_K RAM:TEMP_K
ENDIF
ENDIF
IF $OPT EQ "2"
DIR >RAM:TEMP_K2
CD RAM:
SORT TEMP_K2 TEMP_K
MV_K TEMP_K
ENDIF
IF $OPT EQ "3"
LIST >RAM:TEMP_K2
cd ram:
SORT TEMP_K2 TEMP_K
MV_K TEMP_K
ENDIF
IF $OPT EQ "4"
LIST > RAM:TEMP_K2
cd ram:
SORT TEMP_K2 TEMP_K COLSTART 28
MV_K TEMP_K
ENDIF
IF $OPT EQ "5"
requestchoice >env:FT "SortK" "SELECT TYPE" "FILE" "DIR" "LIST" "ABORT"
IF $FT EQ "0"
SKIP TEST
ENDIF
IF $FT EQ "1"
SKIP FILE
ENDIF
IF $FT EQ "2"
SKIP DIRY
ENDIF
IF $FT EQ "3"
SKIP LISTS
ENDIF
LAB FILE
IF $FT EQ "1"
REQUESTFILE >ENV:FILE1 TITLE="SORT FROM"
CD RAM:
SORT $FILE1 TEMP_K CASE
MV_K TEMP_K
SKIP TEST
ENDIF
LAB DIRY
IF $FT EQ "2"
REQUESTFILE >ENV:FILE1 TITLE="SORT FROM" DRAWERSONLY
CD $FILE1
DIR >RAM:TEMP_K2
CD RAM:
SORT TEMP_K2 TEMP_K CASE
MV_K TEMP_K
SKIP TEST
ENDIF
LAB LISTS
IF $FT EQ "3"
REQUESTFILE >ENV:FILE1 TITLE="SORT FROM" DRAWERSONLY
CD $FILE1
LIST >RAM:TEMP_K2
CD RAM:
SORT TEMP_K2 TEMP_K CASE
MV_K TEMP_K
SKIP TEST
ENDIF
ENDIF
IF $OPT EQ "6"
requestchoice >env:FT "SortK" "SELECT TYPE" "FILE" "DIR" "LIST" "ABORT"
IF $FT EQ "0"
SKIP TEST
ENDIF
IF $FT EQ "1"
SKIP FILEN
ENDIF
IF $FT EQ "2"
SKIP DIRYN
ENDIF
IF $FT EQ "3"
SKIP LISTSN
ENDIF
LAB FILEN
IF $FT EQ "1"
REQUESTFILE >ENV:FILE1 TITLE="SORT FROM"
SORT $FILE1 RAM:TEMP_K NUMERIC
CD RAM:
MV_K TEMP_K
SKIP TEST
ENDIF
LAB DIRYN
IF $FT EQ "2"
REQUESTFILE >ENV:FILE1 TITLE="SORT FROM" DRAWERSONLY
CD $FILE1
DIR >RAM:TEMP_K2
CD RAM:
SORT FROM TEMP_K2 TO TEMP_K NUMERIC
MV_K TEMP_K
SKIP TEST
ENDIF
LAB LISTSN
IF $FT EQ "3"
REQUESTFILE >ENV:FILE1 TITLE="SORT FROM" DRAWERSONLY
CD $FILE1
LIST >RAM:TEMP_K2
CD RAM:
SORT TEMP_K2 TEMP_K NUMERIC
MV_K TEMP_K
ENDIF
ENDIF
LAB TEST
SKIP START BACK
LAB DONE
DELETE RAM:TEMP_K#? QUIET