parsing a structure of bool type

Yariv S.
Airport city,

Dec 28, 2020
2 Posts

0  |  0  

Re: parsing a structure of bool type

Hi,
I have a bigger structure with names of Type BOOL.
During a procedure I modify "False" or "True"

How do I parse this structure on Name and value, like I used to do with an array?
Thanks for any hints
YS

Solution Available
DrATEasy (Ron Y.)
Mission Viejo, CA

Dec 28, 2020
367 Posts

1  |  0  

Re: parsing a structure of bool type

You can assign the structure to a variant. ATEasy will create an array and store inside the variant. Howvere there is no way to retrieve value based on the firld name (similar to JSON)- only the field index can be used.

Ronnie

Tero S.
Irvine, CA

Dec 28, 2020
16 Posts

0  |  0  

Re: parsing a structure of bool type

Hi Yariv,

You could try using:
MemoryCopy(&bBoolTemp, &stStructWithBools+wOffset, sizeof(bBoolTemp))
, where wOffset=0 gives you the first stStructWithBools field's address, wOffset=2 the next field's etc. and bBoolTemp contains the field's value

Regards,
Tero



Please Note
You need to have a M@GIC account to participate in the Forums.
Not yet registered on our website? Click here to register today!

All content, information and opinions presented on the Marvin Test Solutions User Forums are those of the authors of the posts and messages and not Marvin Test Solutions'. All attachments and files are downloaded at your own risk. [Read More]