home *** CD-ROM | disk | FTP | other *** search
/ Media Share 9 / MEDIASHARE_09.ISO / progmisc / nfsrc21.zip / RMDIR.ASM < prev    next >
Assembly Source File  |  1991-08-16  |  2KB  |  80 lines

  1. ; File......: RMDIR.ASM
  2. ; Author....: Ted Means
  3. ; Date......: $Date:   15 Aug 1991 23:07:12  $
  4. ; Revision..: $Revision:   1.2  $
  5. ; Log file..: $Logfile:   E:/nanfor/src/rmdir.asv  $
  6. ; This function is an original work by Ted Means and is placed in the
  7. ; public domain.
  8. ;
  9. ; Modification history:
  10. ; ---------------------
  11. ;
  12. ; $Log:   E:/nanfor/src/rmdir.asv  $
  13. ;  
  14. ;     Rev 1.2   15 Aug 1991 23:07:12   GLENN
  15. ;  Forest Belt proofread/edited/cleaned up doc
  16. ;  
  17. ;     Rev 1.1   14 Jun 1991 19:54:58   GLENN
  18. ;  Minor edit to file header
  19. ;  
  20. ;     Rev 1.0   01 Apr 1991 01:03:52   GLENN
  21. ;  Nanforum Toolkit
  22. ;  
  23. ;
  24.  
  25.  
  26. ;  $DOC$
  27. ;  $FUNCNAME$
  28. ;      FT_RMDIR()
  29. ;  $CATEGORY$
  30. ;      DOS/BIOS
  31. ;  $ONELINER$
  32. ;      Delete a subdirectory
  33. ;  $SYNTAX$
  34. ;      FT_RMDIR( <cDirName> ) -> nResult
  35. ;  $ARGUMENTS$
  36. ;      <cDirName> is the name of the directory to delete.
  37. ;  $RETURNS$
  38. ;       0  if successful
  39. ;       3  if Path Not Found
  40. ;       5  if Access Denied (directory not empty)
  41. ;      16  if attempt to delete current directory.
  42. ;      99  if invalid parameters passed
  43. ;  $DESCRIPTION$
  44. ;     This function is useful if you need to remove a subdirectory for
  45. ;     some reason.
  46. ;
  47. ;     The source code is written to adhere to Turbo Assembler's IDEAL mode.
  48. ;     To use another assembler, you will need to rearrange the PROC and
  49. ;     SEGMENT directives, and also the ENDP and ENDS directives (a very
  50. ;     minor task).
  51. ;  $EXAMPLES$
  52. ;     FT_RMDIR( "C:\CLIPPER" )
  53. ;     FT_RMDIR( "\EXAMPLE" )
  54. ;     FT_RMDIR( "..\SOURCE" )
  55. ;  $END$
  56. ;
  57.  
  58.  
  59.          IDEAL
  60.  
  61. Public   FT_RMDIR
  62.  
  63. Extrn    __ftdir:Far
  64.  
  65. Segment  _NanFor   Word      Public    "CODE"
  66.          Assume    CS:_NanFor
  67.  
  68. Proc     FT_RMDIR  Far
  69.  
  70.          Mov       AH,3Ah                    ; DOS service--remove directory
  71.          Push      AX                        ; Save on stack
  72.          Call      __ftdir                   ; Call generic directory routine
  73.          Add       SP,2                      ; Realign stack
  74.          Ret
  75. Endp     FT_RMDIR
  76. Ends     _NanFor
  77. End
  78. 
  79.