要不你们把代码复制过去自己试试,是不是我的编译器设置错了
你看到结果了吗 ?去掉了那个 编译运行的
.386 .model flat, stdcall option casemap :none include windows.inc include user32.inc include kernel32.inc include masm32.inc includelib user32.lib includelib kernel32.lib includelib masm32.lib include macro.asm __UNICODE__ equ 1 .data? buffer db 100 dup(?) .CODE START: IFNDEF __UNICODE__ int 3h ENDIF invoke StdOut,CTXT("Hello World!") ;暂停显示,回车键关闭 invoke StdIn,addr buffer,sizeof buffer invoke ExitProcess,0 end START
.386 .model flat,stdcall option casemap:none ;>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ; Include 文件定义 ;>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> include windows.inc include user32.inc includelib user32.lib include kernel32.inc includelib kernel32.lib ;>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ; 数据段 __UNICODE__ equ 1 ;>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> .const szCaption db '恭喜',0 szText db '当您看到这个信息的时候,您已经可以编译Win32汇编程序了!',0 ;>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ; 代码段 ;>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> .code start: IFDEF __UNICODE__ MessageBoxEx equ <MessageBoxExW> ENDIF invoke MessageBoxEx,NULL,offset szText,offset szCaption,MB_OK,NULL invoke ExitProcess,NULL ;>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> end start这个代码可以将messageboxex变为messageboxexw