The MASM Forum

General => The Campus => Topic started by: Farabi on December 16, 2012, 12:18:48 PM

Title: How to use it right
Post by: Farabi on December 16, 2012, 12:18:48 PM
I want to access the value refferenced by a variable, how to access it

mov dword ptr[var+4],eax

or

mov [var+4],eax
Title: Re: How to use it right
Post by: qWord on December 16, 2012, 12:23:46 PM
you must load the pointer into a register for dereferencing:
mov eax,pointer
mov DWORD ptr [eax+4],xyz
Title: Re: How to use it right
Post by: Farabi on December 16, 2012, 12:25:09 PM
O I C, I need to the conventional way. Thanks.