【发布时间】:2013-03-05 10:04:01
【问题描述】:
我只是汇编编程的初学者。这是我正在尝试的代码,但它一直返回错误。
错误是:
F:\masm32\bin>ml PRINTSTRING.ASM
Microsoft (R) Macro Assembler Version 6.14.8444
Copyright (C) Microsoft Corp 1981-1997. All rights reserved.
Assembling: PRINTSTRING.ASM
PRINTSTRING.ASM(35) : fatal error A1010: unmatched block nesting : data
我的程序是:
;Print a String
data segment
;add your data here
mymessage db"Enter your data $"
end
stack segment
dw 128 dup(0)
end
code segment
Start:
;Set Segment Registers
mov ax,OFFSET mymessage
mov ds,ax
mov es,ax
lea dx,mymessage
mov ah,mymessage
mov ah,9
int 21h
mov ah,1
int 21h
mov ax,4c00h
int 21h
end
end Start
提前谢谢你。
【问题讨论】:
标签: masm32