flat assembler
Message board for the users of flat assembler.
Index
> DOS > Problem outputting strings |
Author |
|
keyoke 22 Aug 2003, 08:59
this mite work not the best way but it works.
Code: org 100h use16 mov dx,msg mov ah,9 int 21h ;Prints message mov ah,8 int 21h ;Inputs character push ax mov dx, mg mov ah,9 int 21h ;Prints 2nd message pop ax mov dl,al mov ah,2 int 21h ;Prints character entered mov ah,4Ch int 21h ;Quits msg db 'Enter a character ',24h mg db 'You entered:',24h |
|||
22 Aug 2003, 08:59 |
|
Tomasz Grysztar 23 Aug 2003, 23:01
Or you can add the following lines at the beginning of your source:
Code: format MZ push cs pop ds It depends whether you want to make EXE-style or COM-style program. |
|||
23 Aug 2003, 23:01 |
|
Yawgmoth 23 Aug 2003, 23:22
Thanks for your help guys.
|
|||
23 Aug 2003, 23:22 |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2025, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.