Answer the question
In order to leave comments, you need to log in
How to print the numeric value of a variable to the screen in Assembler using the Invoke command?
I want to display the value of a variable in a window.
.386
.model flat, stdcall
option casemap:none
include \masm32\include\windows.inc
include \masm32\include\kernel32.inc
includelib \masm32\lib\kernel32.lib
include \masm32\include\user32.inc
includelib \masm32\lib\user32.lib
.data
num db 1
result db 0
.code
start:
mov ah,num
inc ah
mov [result],ah
invoke MessageBox, NULL, addr result, addr result, 0
invoke ExitProcess, NULL
end start
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question