home *** CD-ROM | disk | FTP | other *** search
/ Microsoft Programmer's Library 1.3 / Microsoft-Programers-Library-v1.3.iso / sampcode / dos_ency / section5 / fxn10h.asm < prev    next >
Encoding:
Assembly Source File  |  1988-08-11  |  1.0 KB  |  21 lines

  1.         ;************************************************************;
  2.         ;                                                            ;
  3.         ;           Function 10H: Close file, FCB-based              ;
  4.         ;                                                            ;
  5.         ;           int FCB_close(oXFCB)                             ;
  6.         ;               char *oXFCB;                                 ;
  7.         ;                                                            ;
  8.         ;           Returns 0 if file closed OK, otherwise           ;
  9.         ;           returns -1.                                      ;
  10.         ;                                                            ;
  11.         ;************************************************************;
  12.  
  13. cProc   FCB_close,PUBLIC,ds
  14. parmDP  poXFCB
  15. cBegin
  16.         loadDP  ds,dx,poXFCB    ; Pointer to opened extended FCB.
  17.         mov     ah,10h          ; Ask MS-DOS to close file.
  18.         int     21h
  19.         cbw                     ; Set return value to 0 or -1.
  20. cEnd
  21.