Skip to content

Instantly share code, notes, and snippets.

@tuttlem
Created November 22, 2012 13:07
Show Gist options
  • Save tuttlem/4131090 to your computer and use it in GitHub Desktop.
Save tuttlem/4131090 to your computer and use it in GitHub Desktop.
MessageBox Masm Heading
; #########################################################################
.386 ; minimum processor needed for 32 bit
.model flat, stdcall ; FLAT memory model & STDCALL calling
option casemap :none ; set code to case sensitive
; #########################################################################
include \masm32\include\windows.inc
include \masm32\include\user32.inc
include \masm32\include\kernel32.inc
includelib \masm32\lib\user32.lib
includelib \masm32\lib\kernel32.lib
; #########################################################################
; szText macro defines a string where ever it is used
szText MACRO Name, Text:VARARG
LOCAL lbl
jmp lbl
Name db Text,0
lbl:
ENDM
; #########################################################################
; WinMain function prototype - this is the entry point
WinMain PROTO :DWORD,:DWORD,:DWORD,:DWORD
; #########################################################################
.data
szCommandLine dd 0 ; point to the command line passed in
hInstance dd 0 ; handle to the application instance
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment