flat assembler
Message board for the users of flat assembler.

Index > Main > structures

Author
Thread Post new topic Reply to topic
Kicer



Joined: 30 Apr 2005
Posts: 34
Location: Poland
Kicer
Hi

i have several structures in the program.
and in eax i have adress of one.
now i would like to excess fileds of structure under this adress (i know them)
for example in that way: mov edx,[eax.field1]
how to do that?
Post 01 Apr 2006, 06:00
View user's profile Send private message Reply with quote
Ancient One



Joined: 28 Feb 2005
Posts: 55
Ancient One
let say field1 is a member of a structure definition named FOO. you can access it like below
Code:
mov edx, [eax+FOO.field1]
    


but you need to use the struct macro (included in fasm windows package) to be able to use this construct.
Post 01 Apr 2006, 08:37
View user's profile Send private message MSN Messenger Reply with quote
Tomasz Grysztar



Joined: 16 Jun 2003
Posts: 7750
Location: Kraków, Poland
Tomasz Grysztar
Post 01 Apr 2006, 09:03
View user's profile Send private message Visit poster's website Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2020, Tomasz Grysztar. Also on YouTube, Twitter.

Website powered by rwasa.