The LazyBoy Library Manual - GetExecName

Part of the System group.

%imacro GetExecName 1
Prefers: ES:DI

Return a register pair pointer to the ASCIIZ string of the executable's fully qualified file name. The Carry Flag will be set if it is not available.

Example:

    GetExecName es:di     ; get the executable file name.