Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- Programmers Reference 0.02b - <b>function 11h (17) search for first matching file, using fcbs</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
Function 11h (17)        Search for First Matching File, Using FCBs

    Searches the current directory for the first matching filename.

       On entry:      AH         11h
                      DS:DX      Pointer to an unopened FCB

       Returns:       AL         00h       If filename match found
                                 FFh       If no filename match found

  --------------------------------------------------------------------------

       Notes:         The intended use of this service is to handle
                      filenames that include '?' wildcard characters. This
                      function begins the process, and Function 12h (18)
                      continues the search for subsequent files.

                      Function 29h (Parse Filename) is useful for creating
                      an unopened FCB in preparation for searching.

                      If a file is found, an unopened FCB will be set up
                      at the current Disk Transfer Address. Before calling
                      this function, you should therefore ensure that
                      there is enough room reserved at the DTA for the
                      FCB; if necessary, use Function 1Ah to set the DTA.

                      If the FCB is an extended FCB, you can specify the
                      attributes of the file you wish to search for. If
                      you specify any combination of the hidden, system,
                      or directory attribute bits, the search will match
                      normal files and also any files with the specified
                      attributes. If you specify the volume-label
                      attribute, however, the function will search only
                      for a volume-label entry. The archive and read-only
                      attributes cannot be used as search criteria.

                      If the search uses an extended FCB, and extended FCB
                      is put in the DTA with the 0FFh signature byte
                      (offset -7) at the start of the DTA.

                      File Control Blocks are a holdover from DOS 1. It is
                      preferable to search for files using functions 4Eh
                      (Find First) and 4Fh (Find Next).

See Also: 12h 1Ah 29h 4Eh 4Fh FCB File Attributes

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson