home *** CD-ROM | disk | FTP | other *** search
- Resident >NIL: C:RequestChoice PURE
- Resident >NIL: C:RequestFile PURE
-
- ; $VER: DMSMaker v1.0 (11.7.96) Richard Burke
-
- lab Start
- if EXISTS ENV:Choice
- delete ENV:Choice >NIL:
- endif
-
- if EXISTS ENV:Tst
- delete ENV:Tst >NIL:
- endif
-
- if EXISTS ENV:V
- delete ENV:V >NIL:
- endif
-
- if EXISTS ENV:Re
- delete ENV:Re >NIL:
- endif
-
- if EXISTS ENV:DMS
- delete ENV:DMS >NIL:
- endif
-
- if EXISTS ENV:De
- delete ENV:De >NIL:
- endif
-
- if EXISTS ENV:DeDev
- delete ENV:DeVol >NIL:
- endif
-
- if EXISTS ENV:Cr
- delete ENV:Cr >NIL:
- endif
-
- if EXISTS ENV:CrSv
- delete ENV:CrSv >NIL:
- endif
-
- if EXISTS ENV:Mode
- delete ENV:Mode >NIL:
- endif
-
- if EXISTS ENV:Mode1
- delete ENV:Mode1 >NIL:
- endif
-
- which DMS all >ENV:DMS
-
- RequestChoice >ENV:Choice "Welcome!" "Welcome to the DMSMaker! Choose an action" "Crunch" "Decrunch" "Repack" "View" "Test" "Quit"
-
- if $Choice EQ 1
- lab Dev
- RequestFile >ENV:Cr DRAWERSONLY TITLE "Choose DEVICE to crunch" POSITIVE "Crunch" NEGATIVE "Return to menu"
- if WARN
- skip Start BACK
- endif
- if NOT EXISTS $Cr
- echo "DEVICE does not exist! Choose again!"
- skip Dev BACK
- endif
- RequestChoice >ENV:Mode1 "Crunch Mode" "Choose degree of crunching" "Best" "None" "Heavy1" "Heavy2" "Return to menu"
- if WARN
- skip Start BACK
- endif
- if $Mode1 EQ 1
- echo "BEST" >ENV:Mode
- endif
- if $Mode1 EQ 2
- echo "NONE" >ENV:Mode
- endif
- if $Mode1 EQ 3
- echo "HEAVY1" >ENV:Mode
- endif
- if $Mode1 EQ 4
- echo "HEAVY2" >ENV:Mode
- endif
- RequestFile >ENV:CrSv TITLE "Save crunched file as..." ACCEPTPATTERN "#?.dms" FILE ".dms" POSITIVE "Save" NEGATIVE "Return to menu"
- if WARN
- skip Start BACK
- endif
- $DMS read $CrSv FROM $Cr CMODE $Mode
- echo "File crunched!"
- endif
-
- if $Choice EQ 2
- lab Dec
- RequestFile >ENV:De TITLE "Choose FILE to decrunch" ACCEPTPATTERN "#?.dms" POSITIVE "Decrunch" NEGATIVE "Return to menu"
- if WARN
- skip Start BACK
- endif
- if NOT EXISTS $De
- echo "FILE does not exist! Choose again!"
- skip Dec BACK
- endif
- lab DecDev
- RequestFile >ENV:DeDev TITLE "Choose DEVICE to decrunch TO" DRAWERSONLY POSITIVE "Write" NEGATIVE "Return to menu"
- if WARN
- skip Start BACK
- endif
- if NOT EXISTS $DeDev
- echo "DEVICE does not exist! Choose again!"
- skip DecDev BACK
- endif
- $DMS write $De TO $DeDev
- echo "File decrunched!"
- endif
-
- if $Choice EQ 3
- lab Rep
- RequestFile >ENV:Re TITLE "Choose FILE to repack" ACCEPTPATTERN "#?.dms" POSITIVE "Repack" NEGATIVE "Return to menu" FILE ".dms"
- if WARN
- skip Start BACK
- endif
- if NOT EXISTS $Re
- echo "File does not exist! Choose again!"
- skip Rep BACK
- endif
- RequestChoice >ENV:Mode1 "Crunch Mode" "Choose degree of crunching" "Best" "None" "Heavy1" "Heavy2" "Return to menu"
- if WARN
- skip Start BACK
- endif
- if $Mode1 EQ 1
- echo "BEST" >ENV:Mode
- endif
- if $Mode1 EQ 2
- echo "NONE" >ENV:Mode
- endif
- if $Mode1 EQ 3
- echo "HEAVY1" >ENV:Mode
- endif
- if $Mode1 EQ 4
- echo "HEAVY2" >ENV:Mode
- endif
- RequestFile >ENV:CrSv TITLE "Save repacked file as..." ACCEPTPATTERN "#?.dms" FILE ".dms" POSITIVE "Save" NEGATIVE "Return to menu"
- if WARN
- skip Start BACK
- endif
- $DMS repack $Re TO $CrSv CMODE $Mode
- echo "File repacked!"
- endif
-
- if $Choice EQ 4
- lab View
- RequestFile >ENV:V TITLE "Choose DMS FILE to view" POSITIVE "View" NEGATIVE "Return to menu" ACCEPTPATTERN "#?.dms" FILE ".dms"
- if WARN
- skip Start BACK
- endif
- if NOT EXISTS $V
- echo "FILE does not exist! Choose again!"
- skip View BACK
- endif
- $DMS view $V
- endif
-
- if $Choice EQ 5
- lab Test
- RequestFile >ENV:Tst TITLE "Choose FILE to test" ACCEPTPATTERN "#?.DMS" POSITIVE "Test" NEGATIVE "Return to menu" FILE ".dms"
- if WARN
- skip Start BACK
- endif
- if NOT EXISTS $Tst
- echo "FILE does not exist! Choose again!"
- skip Test BACK
- endif
- $DMS test $Tst
- endif
-
- if $Choice EQ 0
- skip End
- endif
-
- skip Start BACK
-
- lab End
- quit