Home » Personal collection » Acorn ADFS disks » Electron_User_Group » EUG_28.ADF » F/+HINT8

F/+HINT8

This website contains an archive of files for the Acorn Electron, BBC Micro, Acorn Archimedes, Commodore 16 and Commodore 64 computers, which Dominic Ford has rescued from his private collection of floppy disks and cassettes.

Some of these files were originally commercial releases in the 1980s and 1990s, but they are now widely available online. I assume that copyright over them is no longer being asserted. If you own the copyright and would like files to be removed, please contact me.

Tape/disk: Home » Personal collection » Acorn ADFS disks » Electron_User_Group » EUG_28.ADF
Filename: F/+HINT8
Read OK:
File size: 17E2 bytes
Load address: 48204556
Exec address: 34544E49
File contents
        GETFLD          General field locate routine; can locate a field in                          the header, format file or curr
ent record.
        GETFRC          Find the address of a field in the current record.
        GETXFL          Return first non-space character of a field in the A
                        register, folded to upper case if applicable.
        SETDPS          Set the address of the beginning of the current
                        record.
        CHKEOF          Check the character in the A register for an end of
                        field character.
        CHKEOR          Check the character in the A register for an end of
                        record character.
        SIZFLD          Return the size of a given field.
        CMPFLD          Compare two fields of the same type and set the
                        flags.
        SCHFLD          Return the number of a field, given its name.
        SCHFLN          Return the next field number, given a name, for an 
                        ambiguous name specification.

        GETWID          Return the display width for a particular field.
        GETKYW          Return the key width for a particular field.
        CALSBN          Calculate the number of spaces required to be output
                        before a numeric field to right justify it within
                        the display width.

GETFLD

This routine locates a field in either the database header, the format file
or the current record.  If the field is in the current record, the address
of the first character of the field is set into TEMP06 and also into TEMP07. 
If the field is in the format file, TEMP07 is left unaltered, and the
address of the field is put into TEMP06.

If X is equal to 255, then the routine uses the value in the Y register to
locate a record in a list of current records.  The list of records is
numbered from 0 onwards.  The usual way to use this part of the routine will
be with Y set to zero, in order to locate a field within a single current
record.  If you are using a list of records, then you must not set Y to too
high a value, so that the routine runs off the end of the list, unless you
have an end of file marker after the last record.

Before you use this routine, you must have set the position of the first
record in the list by using the SETDPS call.

On entry:               A               field number of field to locate;
                                        field start at 1.
                        X=0             find field in header record.
                        X=1 to          find field in format file record; X
                        X=254           gives the number of the format file
                                        record.
                        X=255           find field in list of current
                                        records; Y has the number of the
                                        record to search, starting at zero.
                        Y               only significant if X=255.

On exit:                CS              field or record not found; TEMP06
                                        (and TEMP07 if X=255) point to the
                                        end of record marker if field not
                                        found, the end of file marker if
                                        record not found.
                        CC              field and record found; TEMP06
                                        points to the beginning of the
                                        field; if the call was made with
                                        X=255 then TEMP07 also points to the
                                        beginning of the field.
                        A,Y             undefined.
                        X               preserved.


GETFRC

This call first sets X to 255, and then calls the GETFLD routine.  The entry
and exit conditions are as for GETFLD when X-255, except that X will always
return set to 255.


GETXFL

GETXFL returns the first non-space character in a field, folded to upper
case if alphabetic.  It is intended primarily for reading the value of
single character fields in the format file, such as the "Field type" field.

GETXFL first calls the routine GETFLD.  The entry conditions are the same as
GETFLD.  If the call to GETFLD fails, ie the Carry flag is set, then the A
register is cleared, and the routine ends.  If the field is  found, then the
first character of the field is returned, folded to upper case if
alphabetic.  If the field is blank, then the end of field marker will be
returned.

On entry:               See GETFLD

On exit:                        TEMP06 and TEMP07 set as for GETFLD.
                        CS      field or record not found, as GETFLD; A set                                  to zero.
                        CC      field found; A contains first non-space
                                character, folded to upper case if
                                alphabetic.
                        X,Y     See GETFLD.

SETDPS

This routine stores the address of the records to be used when using one of
the field locate routines with X set to 255.  It should be called whenever
the address of one of the records in the list or of one of the fields in the
records has altered.  It need not be called if none of the fields has moved,
since ViewStore will keep track of its position in the list of records, and
move backwards or forwards as necessary to find the field you have asked
for.

If you are reading records one by one using the NXTIMF call, for example,
then you must call SETDPS with their address of the record for each record
that you read: the alignment of the fields will alter for each record.

On entry:       A               contains low byte of the address of the first
                                record in the list.
                Y               contains the high byte of the address of the 
                                first record in the list.

On exit:        A,X,Y           undefined.

00000000  0d 20 20 20 20 20 20 20  20 47 45 54 46 4c 44 20  |.        GETFLD |
00000010  20 20 20 20 20 20 20 20  20 47 65 6e 65 72 61 6c  |         General|
00000020  20 66 69 65 6c 64 20 6c  6f 63 61 74 65 20 72 6f  | field locate ro|
00000030  75 74 69 6e 65 3b 20 63  61 6e 20 6c 6f 63 61 74  |utine; can locat|
00000040  65 20 61 20 66 69 65 6c  64 20 69 6e 20 20 20 20  |e a field in    |
00000050  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |                |
00000060  20 20 20 20 20 20 74 68  65 20 68 65 61 64 65 72  |      the header|
00000070  2c 20 66 6f 72 6d 61 74  20 66 69 6c 65 20 6f 72  |, format file or|
00000080  20 63 75 72 72 0d 65 6e  74 20 72 65 63 6f 72 64  | curr.ent record|
00000090  2e 0d 20 20 20 20 20 20  20 20 47 45 54 46 52 43  |..        GETFRC|
000000a0  20 20 20 20 20 20 20 20  20 20 46 69 6e 64 20 74  |          Find t|
000000b0  68 65 20 61 64 64 72 65  73 73 20 6f 66 20 61 20  |he address of a |
000000c0  66 69 65 6c 64 20 69 6e  20 74 68 65 20 63 75 72  |field in the cur|
000000d0  72 65 6e 74 20 72 65 63  6f 72 64 2e 0d 20 20 20  |rent record..   |
000000e0  20 20 20 20 20 47 45 54  58 46 4c 20 20 20 20 20  |     GETXFL     |
000000f0  20 20 20 20 20 52 65 74  75 72 6e 20 66 69 72 73  |     Return firs|
00000100  74 20 6e 6f 6e 2d 73 70  61 63 65 20 63 68 61 72  |t non-space char|
00000110  61 63 74 65 72 20 6f 66  20 61 20 66 69 65 6c 64  |acter of a field|
00000120  20 69 6e 20 74 68 65 20  41 0d 20 20 20 20 20 20  | in the A.      |
00000130  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |                |
00000140  20 20 72 65 67 69 73 74  65 72 2c 20 66 6f 6c 64  |  register, fold|
00000150  65 64 20 74 6f 20 75 70  70 65 72 20 63 61 73 65  |ed to upper case|
00000160  20 69 66 20 61 70 70 6c  69 63 61 62 6c 65 2e 0d  | if applicable..|
00000170  20 20 20 20 20 20 20 20  53 45 54 44 50 53 20 20  |        SETDPS  |
00000180  20 20 20 20 20 20 20 20  53 65 74 20 74 68 65 20  |        Set the |
00000190  61 64 64 72 65 73 73 20  6f 66 20 74 68 65 20 62  |address of the b|
000001a0  65 67 69 6e 6e 69 6e 67  20 6f 66 20 74 68 65 20  |eginning of the |
000001b0  63 75 72 72 65 6e 74 0d  20 20 20 20 20 20 20 20  |current.        |
000001c0  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |                |
000001d0  72 65 63 6f 72 64 2e 0d  20 20 20 20 20 20 20 20  |record..        |
000001e0  43 48 4b 45 4f 46 20 20  20 20 20 20 20 20 20 20  |CHKEOF          |
000001f0  43 68 65 63 6b 20 74 68  65 20 63 68 61 72 61 63  |Check the charac|
00000200  74 65 72 20 69 6e 20 74  68 65 20 41 20 72 65 67  |ter in the A reg|
00000210  69 73 74 65 72 20 66 6f  72 20 61 6e 20 65 6e 64  |ister for an end|
00000220  20 6f 66 0d 20 20 20 20  20 20 20 20 20 20 20 20  | of.            |
00000230  20 20 20 20 20 20 20 20  20 20 20 20 66 69 65 6c  |            fiel|
00000240  64 20 63 68 61 72 61 63  74 65 72 2e 0d 20 20 20  |d character..   |
00000250  20 20 20 20 20 43 48 4b  45 4f 52 20 20 20 20 20  |     CHKEOR     |
00000260  20 20 20 20 20 43 68 65  63 6b 20 74 68 65 20 63  |     Check the c|
00000270  68 61 72 61 63 74 65 72  20 69 6e 20 74 68 65 20  |haracter in the |
00000280  41 20 72 65 67 69 73 74  65 72 20 66 6f 72 20 61  |A register for a|
00000290  6e 20 65 6e 64 20 6f 66  0d 20 20 20 20 20 20 20  |n end of.       |
000002a0  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |                |
000002b0  20 72 65 63 6f 72 64 20  63 68 61 72 61 63 74 65  | record characte|
000002c0  72 2e 0d 20 20 20 20 20  20 20 20 53 49 5a 46 4c  |r..        SIZFL|
000002d0  44 20 20 20 20 20 20 20  20 20 20 52 65 74 75 72  |D          Retur|
000002e0  6e 20 74 68 65 20 73 69  7a 65 20 6f 66 20 61 20  |n the size of a |
000002f0  67 69 76 65 6e 20 66 69  65 6c 64 2e 0d 20 20 20  |given field..   |
00000300  20 20 20 20 20 43 4d 50  46 4c 44 20 20 20 20 20  |     CMPFLD     |
00000310  20 20 20 20 20 43 6f 6d  70 61 72 65 20 74 77 6f  |     Compare two|
00000320  20 66 69 65 6c 64 73 20  6f 66 20 74 68 65 20 73  | fields of the s|
00000330  61 6d 65 20 74 79 70 65  20 61 6e 64 20 73 65 74  |ame type and set|
00000340  20 74 68 65 0d 20 20 20  20 20 20 20 20 20 20 20  | the.           |
00000350  20 20 20 20 20 20 20 20  20 20 20 20 20 66 6c 61  |             fla|
00000360  67 73 2e 0d 20 20 20 20  20 20 20 20 53 43 48 46  |gs..        SCHF|
00000370  4c 44 20 20 20 20 20 20  20 20 20 20 52 65 74 75  |LD          Retu|
00000380  72 6e 20 74 68 65 20 6e  75 6d 62 65 72 20 6f 66  |rn the number of|
00000390  20 61 20 66 69 65 6c 64  2c 20 67 69 76 65 6e 20  | a field, given |
000003a0  69 74 73 20 6e 61 6d 65  2e 0d 20 20 20 20 20 20  |its name..      |
000003b0  20 20 53 43 48 46 4c 4e  20 20 20 20 20 20 20 20  |  SCHFLN        |
000003c0  20 20 52 65 74 75 72 6e  20 74 68 65 20 6e 65 78  |  Return the nex|
000003d0  74 20 66 69 65 6c 64 20  6e 75 6d 62 65 72 2c 20  |t field number, |
000003e0  67 69 76 65 6e 20 61 20  6e 61 6d 65 2c 20 66 6f  |given a name, fo|
000003f0  72 20 61 6e 20 0d 20 20  20 20 20 20 20 20 20 20  |r an .          |
00000400  20 20 20 20 20 20 20 20  20 20 20 20 20 20 61 6d  |              am|
00000410  62 69 67 75 6f 75 73 20  6e 61 6d 65 20 73 70 65  |biguous name spe|
00000420  63 69 66 69 63 61 74 69  6f 6e 2e 0d 0d 20 20 20  |cification...   |
00000430  20 20 20 20 20 47 45 54  57 49 44 20 20 20 20 20  |     GETWID     |
00000440  20 20 20 20 20 52 65 74  75 72 6e 20 74 68 65 20  |     Return the |
00000450  64 69 73 70 6c 61 79 20  77 69 64 74 68 20 66 6f  |display width fo|
00000460  72 20 61 20 70 61 72 74  69 63 75 6c 61 72 20 66  |r a particular f|
00000470  69 65 6c 64 2e 0d 20 20  20 20 20 20 20 20 47 45  |ield..        GE|
00000480  54 4b 59 57 20 20 20 20  20 20 20 20 20 20 52 65  |TKYW          Re|
00000490  74 75 72 6e 20 74 68 65  20 6b 65 79 20 77 69 64  |turn the key wid|
000004a0  74 68 20 66 6f 72 20 61  20 70 61 72 74 69 63 75  |th for a particu|
000004b0  6c 61 72 20 66 69 65 6c  64 2e 0d 20 20 20 20 20  |lar field..     |
000004c0  20 20 20 43 41 4c 53 42  4e 20 20 20 20 20 20 20  |   CALSBN       |
000004d0  20 20 20 43 61 6c 63 75  6c 61 74 65 20 74 68 65  |   Calculate the|
000004e0  20 6e 75 6d 62 65 72 20  6f 66 20 73 70 61 63 65  | number of space|
000004f0  73 20 72 65 71 75 69 72  65 64 20 74 6f 20 62 65  |s required to be|
00000500  20 6f 75 74 70 75 74 0d  20 20 20 20 20 20 20 20  | output.        |
00000510  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |                |
00000520  62 65 66 6f 72 65 20 61  20 6e 75 6d 65 72 69 63  |before a numeric|
00000530  20 66 69 65 6c 64 20 74  6f 20 72 69 67 68 74 20  | field to right |
00000540  6a 75 73 74 69 66 79 20  69 74 20 77 69 74 68 69  |justify it withi|
00000550  6e 0d 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |n.              |
00000560  20 20 20 20 20 20 20 20  20 20 74 68 65 20 64 69  |          the di|
00000570  73 70 6c 61 79 20 77 69  64 74 68 2e 0d 0d 47 45  |splay width...GE|
00000580  54 46 4c 44 0d 0d 54 68  69 73 20 72 6f 75 74 69  |TFLD..This routi|
00000590  6e 65 20 6c 6f 63 61 74  65 73 20 61 20 66 69 65  |ne locates a fie|
000005a0  6c 64 20 69 6e 20 65 69  74 68 65 72 20 74 68 65  |ld in either the|
000005b0  20 64 61 74 61 62 61 73  65 20 68 65 61 64 65 72  | database header|
000005c0  2c 20 74 68 65 20 66 6f  72 6d 61 74 20 66 69 6c  |, the format fil|
000005d0  65 0d 6f 72 20 74 68 65  20 63 75 72 72 65 6e 74  |e.or the current|
000005e0  20 72 65 63 6f 72 64 2e  20 20 49 66 20 74 68 65  | record.  If the|
000005f0  20 66 69 65 6c 64 20 69  73 20 69 6e 20 74 68 65  | field is in the|
00000600  20 63 75 72 72 65 6e 74  20 72 65 63 6f 72 64 2c  | current record,|
00000610  20 74 68 65 20 61 64 64  72 65 73 73 0d 6f 66 20  | the address.of |
00000620  74 68 65 20 66 69 72 73  74 20 63 68 61 72 61 63  |the first charac|
00000630  74 65 72 20 6f 66 20 74  68 65 20 66 69 65 6c 64  |ter of the field|
00000640  20 69 73 20 73 65 74 20  69 6e 74 6f 20 54 45 4d  | is set into TEM|
00000650  50 30 36 20 61 6e 64 20  61 6c 73 6f 20 69 6e 74  |P06 and also int|
00000660  6f 20 54 45 4d 50 30 37  2e 20 0d 49 66 20 74 68  |o TEMP07. .If th|
00000670  65 20 66 69 65 6c 64 20  69 73 20 69 6e 20 74 68  |e field is in th|
00000680  65 20 66 6f 72 6d 61 74  20 66 69 6c 65 2c 20 54  |e format file, T|
00000690  45 4d 50 30 37 20 69 73  20 6c 65 66 74 20 75 6e  |EMP07 is left un|
000006a0  61 6c 74 65 72 65 64 2c  20 61 6e 64 20 74 68 65  |altered, and the|
000006b0  0d 61 64 64 72 65 73 73  20 6f 66 20 74 68 65 20  |.address of the |
000006c0  66 69 65 6c 64 20 69 73  20 70 75 74 20 69 6e 74  |field is put int|
000006d0  6f 20 54 45 4d 50 30 36  2e 0d 0d 49 66 20 58 20  |o TEMP06...If X |
000006e0  69 73 20 65 71 75 61 6c  20 74 6f 20 32 35 35 2c  |is equal to 255,|
000006f0  20 74 68 65 6e 20 74 68  65 20 72 6f 75 74 69 6e  | then the routin|
00000700  65 20 75 73 65 73 20 74  68 65 20 76 61 6c 75 65  |e uses the value|
00000710  20 69 6e 20 74 68 65 20  59 20 72 65 67 69 73 74  | in the Y regist|
00000720  65 72 20 74 6f 0d 6c 6f  63 61 74 65 20 61 20 72  |er to.locate a r|
00000730  65 63 6f 72 64 20 69 6e  20 61 20 6c 69 73 74 20  |ecord in a list |
00000740  6f 66 20 63 75 72 72 65  6e 74 20 72 65 63 6f 72  |of current recor|
00000750  64 73 2e 20 20 54 68 65  20 6c 69 73 74 20 6f 66  |ds.  The list of|
00000760  20 72 65 63 6f 72 64 73  20 69 73 0d 6e 75 6d 62  | records is.numb|
00000770  65 72 65 64 20 66 72 6f  6d 20 30 20 6f 6e 77 61  |ered from 0 onwa|
00000780  72 64 73 2e 20 20 54 68  65 20 75 73 75 61 6c 20  |rds.  The usual |
00000790  77 61 79 20 74 6f 20 75  73 65 20 74 68 69 73 20  |way to use this |
000007a0  70 61 72 74 20 6f 66 20  74 68 65 20 72 6f 75 74  |part of the rout|
000007b0  69 6e 65 20 77 69 6c 6c  0d 62 65 20 77 69 74 68  |ine will.be with|
000007c0  20 59 20 73 65 74 20 74  6f 20 7a 65 72 6f 2c 20  | Y set to zero, |
000007d0  69 6e 20 6f 72 64 65 72  20 74 6f 20 6c 6f 63 61  |in order to loca|
000007e0  74 65 20 61 20 66 69 65  6c 64 20 77 69 74 68 69  |te a field withi|
000007f0  6e 20 61 20 73 69 6e 67  6c 65 20 63 75 72 72 65  |n a single curre|
00000800  6e 74 0d 72 65 63 6f 72  64 2e 20 20 49 66 20 79  |nt.record.  If y|
00000810  6f 75 20 61 72 65 20 75  73 69 6e 67 20 61 20 6c  |ou are using a l|
00000820  69 73 74 20 6f 66 20 72  65 63 6f 72 64 73 2c 20  |ist of records, |
00000830  74 68 65 6e 20 79 6f 75  20 6d 75 73 74 20 6e 6f  |then you must no|
00000840  74 20 73 65 74 20 59 20  74 6f 20 74 6f 6f 0d 68  |t set Y to too.h|
00000850  69 67 68 20 61 20 76 61  6c 75 65 2c 20 73 6f 20  |igh a value, so |
00000860  74 68 61 74 20 74 68 65  20 72 6f 75 74 69 6e 65  |that the routine|
00000870  20 72 75 6e 73 20 6f 66  66 20 74 68 65 20 65 6e  | runs off the en|
00000880  64 20 6f 66 20 74 68 65  20 6c 69 73 74 2c 20 75  |d of the list, u|
00000890  6e 6c 65 73 73 20 79 6f  75 0d 68 61 76 65 20 61  |nless you.have a|
000008a0  6e 20 65 6e 64 20 6f 66  20 66 69 6c 65 20 6d 61  |n end of file ma|
000008b0  72 6b 65 72 20 61 66 74  65 72 20 74 68 65 20 6c  |rker after the l|
000008c0  61 73 74 20 72 65 63 6f  72 64 2e 0d 0d 42 65 66  |ast record...Bef|
000008d0  6f 72 65 20 79 6f 75 20  75 73 65 20 74 68 69 73  |ore you use this|
000008e0  20 72 6f 75 74 69 6e 65  2c 20 79 6f 75 20 6d 75  | routine, you mu|
000008f0  73 74 20 68 61 76 65 20  73 65 74 20 74 68 65 20  |st have set the |
00000900  70 6f 73 69 74 69 6f 6e  20 6f 66 20 74 68 65 20  |position of the |
00000910  66 69 72 73 74 0d 72 65  63 6f 72 64 20 69 6e 20  |first.record in |
00000920  74 68 65 20 6c 69 73 74  20 62 79 20 75 73 69 6e  |the list by usin|
00000930  67 20 74 68 65 20 53 45  54 44 50 53 20 63 61 6c  |g the SETDPS cal|
00000940  6c 2e 0d 0d 4f 6e 20 65  6e 74 72 79 3a 20 20 20  |l...On entry:   |
00000950  20 20 20 20 20 20 20 20  20 20 20 20 41 20 20 20  |            A   |
00000960  20 20 20 20 20 20 20 20  20 20 20 20 66 69 65 6c  |            fiel|
00000970  64 20 6e 75 6d 62 65 72  20 6f 66 20 66 69 65 6c  |d number of fiel|
00000980  64 20 74 6f 20 6c 6f 63  61 74 65 3b 0d 20 20 20  |d to locate;.   |
00000990  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |                |
*
000009b0  20 20 20 20 20 66 69 65  6c 64 20 73 74 61 72 74  |     field start|
000009c0  20 61 74 20 31 2e 0d 20  20 20 20 20 20 20 20 20  | at 1..         |
000009d0  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 58  |               X|
000009e0  3d 30 20 20 20 20 20 20  20 20 20 20 20 20 20 66  |=0             f|
000009f0  69 6e 64 20 66 69 65 6c  64 20 69 6e 20 68 65 61  |ind field in hea|
00000a00  64 65 72 20 72 65 63 6f  72 64 2e 0d 20 20 20 20  |der record..    |
00000a10  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |                |
00000a20  20 20 20 20 58 3d 31 20  74 6f 20 20 20 20 20 20  |    X=1 to      |
00000a30  20 20 20 20 66 69 6e 64  20 66 69 65 6c 64 20 69  |    find field i|
00000a40  6e 20 66 6f 72 6d 61 74  20 66 69 6c 65 20 72 65  |n format file re|
00000a50  63 6f 72 64 3b 20 58 0d  20 20 20 20 20 20 20 20  |cord; X.        |
00000a60  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |                |
00000a70  58 3d 32 35 34 20 20 20  20 20 20 20 20 20 20 20  |X=254           |
00000a80  67 69 76 65 73 20 74 68  65 20 6e 75 6d 62 65 72  |gives the number|
00000a90  20 6f 66 20 74 68 65 20  66 6f 72 6d 61 74 20 66  | of the format f|
00000aa0  69 6c 65 0d 20 20 20 20  20 20 20 20 20 20 20 20  |ile.            |
00000ab0  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |                |
00000ac0  20 20 20 20 20 20 20 20  20 20 20 20 72 65 63 6f  |            reco|
00000ad0  72 64 2e 0d 20 20 20 20  20 20 20 20 20 20 20 20  |rd..            |
00000ae0  20 20 20 20 20 20 20 20  20 20 20 20 58 3d 32 35  |            X=25|
00000af0  35 20 20 20 20 20 20 20  20 20 20 20 66 69 6e 64  |5           find|
00000b00  20 66 69 65 6c 64 20 69  6e 20 6c 69 73 74 20 6f  | field in list o|
00000b10  66 20 63 75 72 72 65 6e  74 0d 20 20 20 20 20 20  |f current.      |
00000b20  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |                |
*
00000b40  20 20 72 65 63 6f 72 64  73 3b 20 59 20 68 61 73  |  records; Y has|
00000b50  20 74 68 65 20 6e 75 6d  62 65 72 20 6f 66 20 74  | the number of t|
00000b60  68 65 0d 20 20 20 20 20  20 20 20 20 20 20 20 20  |he.             |
00000b70  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |                |
00000b80  20 20 20 20 20 20 20 20  20 20 20 72 65 63 6f 72  |           recor|
00000b90  64 20 74 6f 20 73 65 61  72 63 68 2c 20 73 74 61  |d to search, sta|
00000ba0  72 74 69 6e 67 20 61 74  20 7a 65 72 6f 2e 0d 20  |rting at zero.. |
00000bb0  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |                |
00000bc0  20 20 20 20 20 20 20 59  20 20 20 20 20 20 20 20  |       Y        |
00000bd0  20 20 20 20 20 20 20 6f  6e 6c 79 20 73 69 67 6e  |       only sign|
00000be0  69 66 69 63 61 6e 74 20  69 66 20 58 3d 32 35 35  |ificant if X=255|
00000bf0  2e 0d 0d 4f 6e 20 65 78  69 74 3a 20 20 20 20 20  |...On exit:     |
00000c00  20 20 20 20 20 20 20 20  20 20 20 43 53 20 20 20  |           CS   |
00000c10  20 20 20 20 20 20 20 20  20 20 20 66 69 65 6c 64  |           field|
00000c20  20 6f 72 20 72 65 63 6f  72 64 20 6e 6f 74 20 66  | or record not f|
00000c30  6f 75 6e 64 3b 20 54 45  4d 50 30 36 0d 20 20 20  |ound; TEMP06.   |
00000c40  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |                |
*
00000c60  20 20 20 20 20 28 61 6e  64 20 54 45 4d 50 30 37  |     (and TEMP07|
00000c70  20 69 66 20 58 3d 32 35  35 29 20 70 6f 69 6e 74  | if X=255) point|
00000c80  20 74 6f 20 74 68 65 0d  20 20 20 20 20 20 20 20  | to the.        |
00000c90  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |                |
*
00000cb0  65 6e 64 20 6f 66 20 72  65 63 6f 72 64 20 6d 61  |end of record ma|
00000cc0  72 6b 65 72 20 69 66 20  66 69 65 6c 64 20 6e 6f  |rker if field no|
00000cd0  74 0d 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |t.              |
00000ce0  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |                |
00000cf0  20 20 20 20 20 20 20 20  20 20 66 6f 75 6e 64 2c  |          found,|
00000d00  20 74 68 65 20 65 6e 64  20 6f 66 20 66 69 6c 65  | the end of file|
00000d10  20 6d 61 72 6b 65 72 20  69 66 0d 20 20 20 20 20  | marker if.     |
00000d20  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |                |
*
00000d40  20 20 20 72 65 63 6f 72  64 20 6e 6f 74 20 66 6f  |   record not fo|
00000d50  75 6e 64 2e 0d 20 20 20  20 20 20 20 20 20 20 20  |und..           |
00000d60  20 20 20 20 20 20 20 20  20 20 20 20 20 43 43 20  |             CC |
00000d70  20 20 20 20 20 20 20 20  20 20 20 20 20 66 69 65  |             fie|
00000d80  6c 64 20 61 6e 64 20 72  65 63 6f 72 64 20 66 6f  |ld and record fo|
00000d90  75 6e 64 3b 20 54 45 4d  50 30 36 0d 20 20 20 20  |und; TEMP06.    |
00000da0  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |                |
*
00000dc0  20 20 20 20 70 6f 69 6e  74 73 20 74 6f 20 74 68  |    points to th|
00000dd0  65 20 62 65 67 69 6e 6e  69 6e 67 20 6f 66 20 74  |e beginning of t|
00000de0  68 65 0d 20 20 20 20 20  20 20 20 20 20 20 20 20  |he.             |
00000df0  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |                |
00000e00  20 20 20 20 20 20 20 20  20 20 20 66 69 65 6c 64  |           field|
00000e10  3b 20 69 66 20 74 68 65  20 63 61 6c 6c 20 77 61  |; if the call wa|
00000e20  73 20 6d 61 64 65 20 77  69 74 68 0d 20 20 20 20  |s made with.    |
00000e30  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |                |
*
00000e50  20 20 20 20 58 3d 32 35  35 20 74 68 65 6e 20 54  |    X=255 then T|
00000e60  45 4d 50 30 37 20 61 6c  73 6f 20 70 6f 69 6e 74  |EMP07 also point|
00000e70  73 20 74 6f 20 74 68 65  0d 20 20 20 20 20 20 20  |s to the.       |
00000e80  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |                |
*
00000ea0  20 62 65 67 69 6e 6e 69  6e 67 20 6f 66 20 74 68  | beginning of th|
00000eb0  65 20 66 69 65 6c 64 2e  0d 20 20 20 20 20 20 20  |e field..       |
00000ec0  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |                |
00000ed0  20 41 2c 59 20 20 20 20  20 20 20 20 20 20 20 20  | A,Y            |
00000ee0  20 75 6e 64 65 66 69 6e  65 64 2e 0d 20 20 20 20  | undefined..    |
00000ef0  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |                |
00000f00  20 20 20 20 58 20 20 20  20 20 20 20 20 20 20 20  |    X           |
00000f10  20 20 20 20 70 72 65 73  65 72 76 65 64 2e 0d 0d  |    preserved...|
00000f20  0d 47 45 54 46 52 43 0d  0d 54 68 69 73 20 63 61  |.GETFRC..This ca|
00000f30  6c 6c 20 66 69 72 73 74  20 73 65 74 73 20 58 20  |ll first sets X |
00000f40  74 6f 20 32 35 35 2c 20  61 6e 64 20 74 68 65 6e  |to 255, and then|
00000f50  20 63 61 6c 6c 73 20 74  68 65 20 47 45 54 46 4c  | calls the GETFL|
00000f60  44 20 72 6f 75 74 69 6e  65 2e 20 20 54 68 65 20  |D routine.  The |
00000f70  65 6e 74 72 79 0d 61 6e  64 20 65 78 69 74 20 63  |entry.and exit c|
00000f80  6f 6e 64 69 74 69 6f 6e  73 20 61 72 65 20 61 73  |onditions are as|
00000f90  20 66 6f 72 20 47 45 54  46 4c 44 20 77 68 65 6e  | for GETFLD when|
00000fa0  20 58 2d 32 35 35 2c 20  65 78 63 65 70 74 20 74  | X-255, except t|
00000fb0  68 61 74 20 58 20 77 69  6c 6c 20 61 6c 77 61 79  |hat X will alway|
00000fc0  73 0d 72 65 74 75 72 6e  20 73 65 74 20 74 6f 20  |s.return set to |
00000fd0  32 35 35 2e 0d 0d 0d 47  45 54 58 46 4c 0d 0d 47  |255....GETXFL..G|
00000fe0  45 54 58 46 4c 20 72 65  74 75 72 6e 73 20 74 68  |ETXFL returns th|
00000ff0  65 20 66 69 72 73 74 20  6e 6f 6e 2d 73 70 61 63  |e first non-spac|
00001000  65 20 63 68 61 72 61 63  74 65 72 20 69 6e 20 61  |e character in a|
00001010  20 66 69 65 6c 64 2c 20  66 6f 6c 64 65 64 20 74  | field, folded t|
00001020  6f 20 75 70 70 65 72 0d  63 61 73 65 20 69 66 20  |o upper.case if |
00001030  61 6c 70 68 61 62 65 74  69 63 2e 20 20 49 74 20  |alphabetic.  It |
00001040  69 73 20 69 6e 74 65 6e  64 65 64 20 70 72 69 6d  |is intended prim|
00001050  61 72 69 6c 79 20 66 6f  72 20 72 65 61 64 69 6e  |arily for readin|
00001060  67 20 74 68 65 20 76 61  6c 75 65 20 6f 66 0d 73  |g the value of.s|
00001070  69 6e 67 6c 65 20 63 68  61 72 61 63 74 65 72 20  |ingle character |
00001080  66 69 65 6c 64 73 20 69  6e 20 74 68 65 20 66 6f  |fields in the fo|
00001090  72 6d 61 74 20 66 69 6c  65 2c 20 73 75 63 68 20  |rmat file, such |
000010a0  61 73 20 74 68 65 20 22  46 69 65 6c 64 20 74 79  |as the "Field ty|
000010b0  70 65 22 20 66 69 65 6c  64 2e 0d 0d 47 45 54 58  |pe" field...GETX|
000010c0  46 4c 20 66 69 72 73 74  20 63 61 6c 6c 73 20 74  |FL first calls t|
000010d0  68 65 20 72 6f 75 74 69  6e 65 20 47 45 54 46 4c  |he routine GETFL|
000010e0  44 2e 20 20 54 68 65 20  65 6e 74 72 79 20 63 6f  |D.  The entry co|
000010f0  6e 64 69 74 69 6f 6e 73  20 61 72 65 20 74 68 65  |nditions are the|
00001100  20 73 61 6d 65 20 61 73  0d 47 45 54 46 4c 44 2e  | same as.GETFLD.|
00001110  20 20 49 66 20 74 68 65  20 63 61 6c 6c 20 74 6f  |  If the call to|
00001120  20 47 45 54 46 4c 44 20  66 61 69 6c 73 2c 20 69  | GETFLD fails, i|
00001130  65 20 74 68 65 20 43 61  72 72 79 20 66 6c 61 67  |e the Carry flag|
00001140  20 69 73 20 73 65 74 2c  20 74 68 65 6e 20 74 68  | is set, then th|
00001150  65 20 41 0d 72 65 67 69  73 74 65 72 20 69 73 20  |e A.register is |
00001160  63 6c 65 61 72 65 64 2c  20 61 6e 64 20 74 68 65  |cleared, and the|
00001170  20 72 6f 75 74 69 6e 65  20 65 6e 64 73 2e 20 20  | routine ends.  |
00001180  49 66 20 74 68 65 20 66  69 65 6c 64 20 69 73 20  |If the field is |
00001190  20 66 6f 75 6e 64 2c 20  74 68 65 6e 20 74 68 65  | found, then the|
000011a0  0d 66 69 72 73 74 20 63  68 61 72 61 63 74 65 72  |.first character|
000011b0  20 6f 66 20 74 68 65 20  66 69 65 6c 64 20 69 73  | of the field is|
000011c0  20 72 65 74 75 72 6e 65  64 2c 20 66 6f 6c 64 65  | returned, folde|
000011d0  64 20 74 6f 20 75 70 70  65 72 20 63 61 73 65 20  |d to upper case |
000011e0  69 66 0d 61 6c 70 68 61  62 65 74 69 63 2e 20 20  |if.alphabetic.  |
000011f0  49 66 20 74 68 65 20 66  69 65 6c 64 20 69 73 20  |If the field is |
00001200  62 6c 61 6e 6b 2c 20 74  68 65 6e 20 74 68 65 20  |blank, then the |
00001210  65 6e 64 20 6f 66 20 66  69 65 6c 64 20 6d 61 72  |end of field mar|
00001220  6b 65 72 20 77 69 6c 6c  20 62 65 0d 72 65 74 75  |ker will be.retu|
00001230  72 6e 65 64 2e 0d 0d 4f  6e 20 65 6e 74 72 79 3a  |rned...On entry:|
00001240  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 53  |               S|
00001250  65 65 20 47 45 54 46 4c  44 0d 0d 4f 6e 20 65 78  |ee GETFLD..On ex|
00001260  69 74 3a 20 20 20 20 20  20 20 20 20 20 20 20 20  |it:             |
00001270  20 20 20 20 20 20 20 20  20 20 20 54 45 4d 50 30  |           TEMP0|
00001280  36 20 61 6e 64 20 54 45  4d 50 30 37 20 73 65 74  |6 and TEMP07 set|
00001290  20 61 73 20 66 6f 72 20  47 45 54 46 4c 44 2e 0d  | as for GETFLD..|
000012a0  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |                |
000012b0  20 20 20 20 20 20 20 20  43 53 20 20 20 20 20 20  |        CS      |
000012c0  66 69 65 6c 64 20 6f 72  20 72 65 63 6f 72 64 20  |field or record |
000012d0  6e 6f 74 20 66 6f 75 6e  64 2c 20 61 73 20 47 45  |not found, as GE|
000012e0  54 46 4c 44 3b 20 41 20  73 65 74 20 20 20 20 20  |TFLD; A set     |
000012f0  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |                |
00001300  20 20 20 20 20 20 20 20  20 20 20 20 20 74 6f 20  |             to |
00001310  7a 65 72 6f 2e 0d 20 20  20 20 20 20 20 20 20 20  |zero..          |
00001320  20 20 20 20 20 20 20 20  20 20 20 20 20 20 43 43  |              CC|
00001330  20 20 20 20 20 20 66 69  65 6c 64 20 66 6f 75 6e  |      field foun|
00001340  64 3b 20 41 20 63 6f 6e  74 61 69 6e 73 20 66 69  |d; A contains fi|
00001350  72 73 74 20 6e 6f 6e 2d  73 70 61 63 65 0d 20 20  |rst non-space.  |
00001360  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |                |
00001370  20 20 20 20 20 20 20 20  20 20 20 20 20 20 63 68  |              ch|
00001380  61 72 61 63 74 65 72 2c  20 66 6f 6c 64 65 64 20  |aracter, folded |
00001390  74 6f 20 75 70 70 65 72  20 63 61 73 65 20 69 66  |to upper case if|
000013a0  0d 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |.               |
000013b0  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |                |
000013c0  20 61 6c 70 68 61 62 65  74 69 63 2e 0d 20 20 20  | alphabetic..   |
000013d0  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |                |
000013e0  20 20 20 20 20 58 2c 59  20 20 20 20 20 53 65 65  |     X,Y     See|
000013f0  20 47 45 54 46 4c 44 2e  0d 0d 53 45 54 44 50 53  | GETFLD...SETDPS|
00001400  0d 0d 54 68 69 73 20 72  6f 75 74 69 6e 65 20 73  |..This routine s|
00001410  74 6f 72 65 73 20 74 68  65 20 61 64 64 72 65 73  |tores the addres|
00001420  73 20 6f 66 20 74 68 65  20 72 65 63 6f 72 64 73  |s of the records|
00001430  20 74 6f 20 62 65 20 75  73 65 64 20 77 68 65 6e  | to be used when|
00001440  20 75 73 69 6e 67 20 6f  6e 65 20 6f 66 0d 74 68  | using one of.th|
00001450  65 20 66 69 65 6c 64 20  6c 6f 63 61 74 65 20 72  |e field locate r|
00001460  6f 75 74 69 6e 65 73 20  77 69 74 68 20 58 20 73  |outines with X s|
00001470  65 74 20 74 6f 20 32 35  35 2e 20 20 49 74 20 73  |et to 255.  It s|
00001480  68 6f 75 6c 64 20 62 65  20 63 61 6c 6c 65 64 20  |hould be called |
00001490  77 68 65 6e 65 76 65 72  0d 74 68 65 20 61 64 64  |whenever.the add|
000014a0  72 65 73 73 20 6f 66 20  6f 6e 65 20 6f 66 20 74  |ress of one of t|
000014b0  68 65 20 72 65 63 6f 72  64 73 20 69 6e 20 74 68  |he records in th|
000014c0  65 20 6c 69 73 74 20 6f  72 20 6f 66 20 6f 6e 65  |e list or of one|
000014d0  20 6f 66 20 74 68 65 20  66 69 65 6c 64 73 20 69  | of the fields i|
000014e0  6e 20 74 68 65 0d 72 65  63 6f 72 64 73 20 68 61  |n the.records ha|
000014f0  73 20 61 6c 74 65 72 65  64 2e 20 20 49 74 20 6e  |s altered.  It n|
00001500  65 65 64 20 6e 6f 74 20  62 65 20 63 61 6c 6c 65  |eed not be calle|
00001510  64 20 69 66 20 6e 6f 6e  65 20 6f 66 20 74 68 65  |d if none of the|
00001520  20 66 69 65 6c 64 73 20  68 61 73 20 6d 6f 76 65  | fields has move|
00001530  64 2c 0d 73 69 6e 63 65  20 56 69 65 77 53 74 6f  |d,.since ViewSto|
00001540  72 65 20 77 69 6c 6c 20  6b 65 65 70 20 74 72 61  |re will keep tra|
00001550  63 6b 20 6f 66 20 69 74  73 20 70 6f 73 69 74 69  |ck of its positi|
00001560  6f 6e 20 69 6e 20 74 68  65 20 6c 69 73 74 20 6f  |on in the list o|
00001570  66 20 72 65 63 6f 72 64  73 2c 20 61 6e 64 0d 6d  |f records, and.m|
00001580  6f 76 65 20 62 61 63 6b  77 61 72 64 73 20 6f 72  |ove backwards or|
00001590  20 66 6f 72 77 61 72 64  73 20 61 73 20 6e 65 63  | forwards as nec|
000015a0  65 73 73 61 72 79 20 74  6f 20 66 69 6e 64 20 74  |essary to find t|
000015b0  68 65 20 66 69 65 6c 64  20 79 6f 75 20 68 61 76  |he field you hav|
000015c0  65 20 61 73 6b 65 64 0d  66 6f 72 2e 0d 0d 49 66  |e asked.for...If|
000015d0  20 79 6f 75 20 61 72 65  20 72 65 61 64 69 6e 67  | you are reading|
000015e0  20 72 65 63 6f 72 64 73  20 6f 6e 65 20 62 79 20  | records one by |
000015f0  6f 6e 65 20 75 73 69 6e  67 20 74 68 65 20 4e 58  |one using the NX|
00001600  54 49 4d 46 20 63 61 6c  6c 2c 20 66 6f 72 20 65  |TIMF call, for e|
00001610  78 61 6d 70 6c 65 2c 0d  74 68 65 6e 20 79 6f 75  |xample,.then you|
00001620  20 6d 75 73 74 20 63 61  6c 6c 20 53 45 54 44 50  | must call SETDP|
00001630  53 20 77 69 74 68 20 74  68 65 69 72 20 61 64 64  |S with their add|
00001640  72 65 73 73 20 6f 66 20  74 68 65 20 72 65 63 6f  |ress of the reco|
00001650  72 64 20 66 6f 72 20 65  61 63 68 20 72 65 63 6f  |rd for each reco|
00001660  72 64 0d 74 68 61 74 20  79 6f 75 20 72 65 61 64  |rd.that you read|
00001670  3a 20 74 68 65 20 61 6c  69 67 6e 6d 65 6e 74 20  |: the alignment |
00001680  6f 66 20 74 68 65 20 66  69 65 6c 64 73 20 77 69  |of the fields wi|
00001690  6c 6c 20 61 6c 74 65 72  20 66 6f 72 20 65 61 63  |ll alter for eac|
000016a0  68 20 72 65 63 6f 72 64  2e 0d 0d 4f 6e 20 65 6e  |h record...On en|
000016b0  74 72 79 3a 20 20 20 20  20 20 20 41 20 20 20 20  |try:       A    |
000016c0  20 20 20 20 20 20 20 20  20 20 20 63 6f 6e 74 61  |           conta|
000016d0  69 6e 73 20 6c 6f 77 20  62 79 74 65 20 6f 66 20  |ins low byte of |
000016e0  74 68 65 20 61 64 64 72  65 73 73 20 6f 66 20 74  |the address of t|
000016f0  68 65 20 66 69 72 73 74  0d 20 20 20 20 20 20 20  |he first.       |
00001700  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |                |
00001710  20 20 20 20 20 20 20 20  20 72 65 63 6f 72 64 20  |         record |
00001720  69 6e 20 74 68 65 20 6c  69 73 74 2e 0d 20 20 20  |in the list..   |
00001730  20 20 20 20 20 20 20 20  20 20 20 20 20 59 20 20  |             Y  |
00001740  20 20 20 20 20 20 20 20  20 20 20 20 20 63 6f 6e  |             con|
00001750  74 61 69 6e 73 20 74 68  65 20 68 69 67 68 20 62  |tains the high b|
00001760  79 74 65 20 6f 66 20 74  68 65 20 61 64 64 72 65  |yte of the addre|
00001770  73 73 20 6f 66 20 74 68  65 20 0d 20 20 20 20 20  |ss of the .     |
00001780  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |                |
00001790  20 20 20 20 20 20 20 20  20 20 20 66 69 72 73 74  |           first|
000017a0  20 72 65 63 6f 72 64 20  69 6e 20 74 68 65 20 6c  | record in the l|
000017b0  69 73 74 2e 0d 0d 4f 6e  20 65 78 69 74 3a 20 20  |ist...On exit:  |
000017c0  20 20 20 20 20 20 41 2c  58 2c 59 20 20 20 20 20  |      A,X,Y     |
000017d0  20 20 20 20 20 20 75 6e  64 65 66 69 6e 65 64 2e  |      undefined.|
000017e0  0d 0d                                             |..|
000017e2
F/+HINT8.m0
F/+HINT8.m1
F/+HINT8.m2
F/+HINT8.m4
F/+HINT8.m5