Hardware Reference
In-Depth Information
If @InStr(1,<TxtMsg>,<ADDR>) eq 0
If @InStr(1,<TxtTitle>,<ADDR>) eq 0
.data
Msg1 db TxtMsg,0
Titl db TxtTitle,0
.code
invoke MessageBox,handl,ADDR Msg1,ADDR Titl,styl
EXITM
EndIf
EndIf
If @InStr(1,<TxtMsg>,<ADDR>) gt 0
If @InStr(1,<TxtTitle>,<ADDR>) eq 0
.data
Titl db TxtTitle,0
.code
invoke MessageBox,handl,TxtMsg,ADDR Titl,styl
EXITM
EndIf
EndIf
If @InStr(1,<TxtMsg>,<ADDR>) eq 0
If @InStr(1,<TxtTitle>,<ADDR>) gt 0
.data
Msg1 db TxtMsg,0
.code
invoke MessageBox,handl,ADDR Msg1,TxtTitle,styl
EXITM
EndIf
EndIf
If @InStr(1,<TxtMsg>,<ADDR>) gt 0
If @InStr(1,<TxtTitle>,<ADDR>) gt 0
invoke MessageBox,handl,TxtMsg,TxtTitle,styl
EXITM
EndIf
EndIf
ENDM
Hopefully, this simple example should help to convince you of the advantages
of using macros and the immense time saving that this can potentially offer the
programmer!
The following data types are supported by MASM32.
Register
Data
Size
al
BYTE
8 bit
ax
WORD
16 bit
eax
DWORD
32 bit
mm(0)
QWORD
64 bit
It is worth comparing the above lost with the complexity of the higher-level
programming languages, such as C ++ which can have as many more data
types! To assist with the conversion of data types a WINDOWS.INC include
file is supplied with MASM32.
Search WWH ::




Custom Search