The LazyBoy Library Manual - StrToQWord

Part of the Strings group.

%imacro StrToQWord 2-3
Prefers: DX:AX, ES:DI

Convert an ASCIIZ string to an unsigned integer. The ASCIIZ can be a string representing a positive integer, hexadecimal or binary number.

A hexadecimal and binary numbers are caseless. A hex number starts with either 0x or simply x.

A binary number contains only 0 and 1 followed by a single b character.

If the value is negative, contains invalid characters or requires more than the bits available in the destination number type, the Carry flag will be set to indicate the string could not be converted.

Both %1 and %2 are pointers. If no segment is provided, then ES is assumed. Unless it is a code label, then CS will be assumed.

If %3 is SIGNED or SINT, then the output will be a signed 32-bit integer and a ASCIIZ string that represents a negative number will be permitted. However the negative symbol is forbidden for strings using hexadecimal or binary representations. For those, the high bit will indicate a negative value.

Examples:

    StrToQWord  dx:ax, di     ; convert string at es:di to an unsigned integer at dx:ax.
    StrToQWord  bx, ASTR      ; convert string at cs:ASTR to an unsigned integer at es:bx.