Int 21H [1.0] Function 1AH (26) Set DTA address

Specifies the address of the disk transfer area (DTA) to be used for subsequent FCB-related function calls.

Call with:

AH = 1AH

DS:DX = segment:offset of disk transfer area

Returns:

Nothing

Notes:

If this function is never called by the program, the DTA defaults to a 128-byte buffer at offset 0080H in the program segment prefix.

In general, it is the programmer's responsibility to ensure that the buffer area specified is large enough for any disk operation that will use it. The only exception to this is that MS-DOS will detect and abort disk transfers that would cause a segment wrap.

Int 21H Function 2FH can be used to determine the current disk transfer address.

The only handle-type operations that rely on the DTA address are the directory search functions, Int 21H Functions 4EH and 4FH.

Example:

Set the current disk transfer area address to the buffer labeled buff.

buff db 128 dup (?)

.

.

.

mov ah,1ah ; function number

mov dx,seg buff ; address of disk

mov ds,dx ; transfer area

mov dx,offset buff

int 21h ; transfer to MS-DOS

.

.

.