How to Start Coding Assembly on Windows (MASM)
Step 1.
Download MASM32: http://masm32.com/masmdl.htm
Step 2.
Save the following Assembly code as “helloworld.asm”
.386
.model flat, stdcall
option casemap :none
include masm32includekernel32.inc
include masm32includemasm32.inc
includelib masm32libkernel32.lib
includelib masm32libmasm32.lib
.data
message db “This is your first assembly program”, 0
.code
main:
invoke StdOut, addr message
invoke ExitProcess, 0
end main
Step 3:
Navigate to the folder you saved the file in. Then compile it into an executable and run it with the following:
set projectName=helloworld
masm32binml /c /Zd /coff %projectName%.asm
masm32binLink /SUBSYSTEM:CONSOLE %projectName%.obj
%projectName%.exe
See more here: http://crclayton.com/projects/assembly-tutorial/
source