home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Fresh Fish 8
/
FreshFishVol8-CD1.bin
/
new
/
biz
/
dbase
/
afile
/
example
/
disks.mask
< prev
next >
Wrap
Text File
|
1994-07-27
|
1KB
|
59 lines
/*
* This is a sample input mask for AFile
* It demonstrates the $MASK, $MENU, $PRINT and $PRINTFMT specifications
*
* $MASK Disks.pic
** Field XPos YPos Width AREXX? Message
* ARTIST 250 39 - - Artist or band
* ALBUM 250 49 - - Album's name
* YEAR 325 59 - CHECK Released year (with century)
* DURATION 204 89 - - Duration in minutes
* PURCHASE 326 145 - CHECK Purchase date
* CD 326 155 - - Set for CD, cleared for K7
* STYLE 266 114 - - Kind of music
* $END
*
* $MENU
** Item Args? Script
* Stats - DisksStats.rexx
* $END
*
* $PRINT DisksPrint.rexx
*
* The above print script produce the same output that the following specification:
** $PRINTFMT %1, %2 (%3)\n
* Try both of them (not at the same time, as told in the doc !)
*/
OPTIONS RESULTS
PARSE ARG Field Value
Value = STRIP( Value )
SAY Field
SAY Value
/*
* Verifies that YEAR is in the YYYY format
*/
IF Field = 'YEAR' THEN DO
IF LENGTH( Value ) = 4 THEN EXIT 0
EXIT 10
END
/*
* Verifies that PURCHASE date is at least greater than released YEAR
* We get PURCHASE value in the YYYYDDMM format
* The YEAR field is in the YYYY format
*/
IF Field = 'PURCHASE' THEN DO
ADDRESS "AFile_rexx"
"GETFIELD YEAR"
IF RESULT <= LEFT( Value , 4 ) THEN EXIT 0
EXIT 10
END
EXIT 10