麻烦高人帮我看看这个程序在哪里出错了?怎么一直编译不过去啊!!
.386
.model flat, stdcall
option casemap:none
include windows.inc
include gdi32.inc
includelib gdi32.lib
include user32.inc
includelib user32.lib
include kernel32.inc
includelib kernel32.lib
.data
hInstance dd ?
hWinMain dd ?
szBuffer db 512 dup(?)
.const
szClassName db 'MyClass', 0
szCaptionMain db 'Recive Message', 0
szRecive db 'Recive Message', 0dh, 0ah
db 'param: %08x', 0dh, 0ah
db 'text : %s', 0dh, 0ah, 0
.code
_ProcWinMain proc uses ebx edi esi, hWnd, uMsg, wParam, lParam
mov eax, uMsg
.if eax == WM_CLOSE
invoke DestroyWindow, hWinMain
invoke PostQuitMessage, NULL
.elseif eax == WM_SETTEXT
invoke wsprintf, addr szBuffer, addr szRecive, wParam, lParam
invoke MessageBox, hWinMain, offset szBuffer, addr szCaptionMain, MB_OK
.else
invoke DefWindowProc, hWnd, uMsg, wParam, lParam
ret
.endif
xor eax, eax
ret
_ProcWinMain endp
_WinMain proc
local @stWndClass:WNDCLASSEX
local @stMsg:MSG
invoke GetModuleHandle, NULL
mov hInstance, eax
invoke RtlZeroMemory, addr @stWndClass, sizeof @stWndClass
invoke LoadCursor, 0, IDC_ARROW
mov @stWndClass.hCursor, eax
mov eax,hInstance
mov @stWndClass.hInstance, eax
mov @stWndClass.cbSize, sizeof WNDCLASSEX
mov @stWndClass.style, CS_HREDRAW or CS_VERDRAW
mov @stWndClass.hbrBackgroud, COLOR_WINDOW + 1
mov @stWndClass.lpszClassName, offset szClassName
invoke RegisterClassEx, addr @stWndClass
invoke CreateWindowEx, WS_EX_CLIENTEDGE, offset szClassName, offset szCaptionMain,\
WS_OVERLAPPEDWINDOW, 50, 50, 200, 150, NULL, NULL, hInstance, NULL
mov hWinMain, eax
invoke ShowWindow, hWinMain, SW_SHOWNORMAL
invoke UpdateWindow,hWinMain
.while TRUE
invoke GetMessage, addr @stMsg, NULL, 0, 0
.break
.if eax == 0
invoke TranslateMessage, addr @stMsg
invoke DispatchMessage, addr @stMsg
.endw
ret
_WinMain endp
start:
call _WinMain
invoke ExitProcess, NULL
end start