Table of Contents
Note: This API call is for DOS and Win16 personality only. Use Family API for portability.
Int 21H, AH=3CH
Version
2 and higher
Brief
“CREAT” - CREATE OR TRUNCATE FILE
Family API
Input
AH = 3Ch CX = file attributes (see #01401) DS:DX -> ASCIZ filename
Return
CF clear if successful AX = file handle CF set on error AX = error code (03h,04h,05h) (see #01680 at AH=59h/BX=0000h)
Notes
if a file with the given name exists, it is truncated to zero length
under the FlashTek X-32 DOS extender, the pointer is in DS:EDX
DR DOS checks the system password or explicitly supplied password at the end of the filename against the reserved field in the directory entry before allowing access
Bitfields for file attributes:
Bit(s) | Description |
---|---|
0 | read-only |
1 | hidden |
2 | system |
3 | volume label (ignored) |
4 | reserved, must be zero (directory) |
5 | archive bit |
7 | if set, file is shareable under Novell NetWare |
See also
Note
Text based on Ralf Brown Interrupt List Release 61
osFree Macro Library | |
---|---|
Video I/O | @SetMode @SetCurSz @SetCurPos @GetCur @SetPage @ScrollUp @ScrollDn @Scroll @GetChAtr @PutChAtr @PutCh @SetPalet @SetColor @SetDot @GetDot @WrtTTY @VideoState @GetMode @GetDisplay @GetVideoState @GetEGAInfo @Cls |
Hardware info | @Equipment @MemSize |
Serial I/O | @AuxInit @AuxSendChar @AuxRecieveChar @AuxStatus |
Tape I/O | @TapeOn @TapeOff @TapeRead @TapeWrite |
Keyboard I/O | @KbdStatus @CharIn @CharPeek |
Printer I/O | @PrnPrint @PrnInit @PrnStatus |
Disk I/O | @DskReset @DskStatus @DskRead @DskWrite @DskVerify @DskFormat |
Date and Time | @SetTime @GetTime |
Mouse | @MouInit @MouShowPointer @MouStatus @MouSetPos @MouSetMickey @MouRegion |
Memory manager | @ModBlok SET_BLOCK |