Ci-dessous, les différences entre deux révisions de la page.
Prochaine révision | Révision précédente | ||
back2root:ibm-pc-ms-dos:interrupts:int_21:int_21_40 [2023/01/10 11:55] – supprimée - modification externe (Unknown date) 127.0.0.1 | back2root:ibm-pc-ms-dos:interrupts:int_21:int_21_40 [2023/01/16 17:54] (Version actuelle) – modification externe 127.0.0.1 | ||
---|---|---|---|
Ligne 1: | Ligne 1: | ||
+ | ====== INT 0x21 - 0x40 - Write To File or Device Using Handle ====== | ||
+ | |||
+ | ===== Request/ | ||
+ | |||
+ | {{tablelayout? | ||
+ | ^ reg ^ value ^ descr ^ | ||
+ | | AH | ||
+ | | BX | ||
+ | | CX | | number of bytes to write, a zero value truncates/ | ||
+ | | DS:DX | pointer to data buffer to write | | ||
+ | |||
+ | ===== Return: ===== | ||
+ | |||
+ | ** CF cleared : success ** | ||
+ | |||
+ | {{tablelayout? | ||
+ | ^ reg ^ | ||
+ | | AX | number of written bytes | | ||
+ | |||
+ | ** CF Set: error ** | ||
+ | |||
+ | {{tablelayout? | ||
+ | ^ reg ^ | ||
+ | | AX | error code (see (see [[back2root: | ||
+ | |||
+ | ===== Notes & Comments ===== | ||
+ | |||
+ | <WRAP round box> | ||
+ | * if AX is not equal to CX on return, a partial write occurred | ||
+ | * this function can be used to truncate a file to the current file position by writing zero bytes | ||
+ | </ | ||
+ | |||
+ | [[start|Back]] | ||