I have been following the assembly tutorials on these forums ( thanks Darguetta and Gokuajmes ) and I made the code below. But I get the error above, and I don't see why. I see that 'exit' is used before it's defined, yet I don't see how it could be done any other way, to get around this.
EDIT: I'm using WinASM
.386 .model flat, stdcall option casemap:none include windows.inc include kernel32.inc includelib kernel32.lib include user32.inc includelib user32.lib .data MsgBoxCaption db "Simple MessageBox Program",0 MsgBoxTextTrue db "TRUE" ,0 MsgBoxTextFalse db "FALSE" ,0 .code mov ebx, 0 cmp ebx, 1 jne DO_FALSE invoke MessageBox, NULL, addr MsgBoxTextTrue, addr MsgBoxCaption, MB_OK jmp exit DO_FALSE: invoke MessageBox, NULL, addr MsgBoxTextFalse, addr MsgBoxCaption, MB_OK end DO_FALSE exit: invoke ExitProcess,0 end exit
Edited by Smilex, 22 February 2011 - 03:26 AM.
Missing information


Sign In
Create Account


Back to top









