Memory access violation after third iteration

Blitz3D Forums/Blitz3D Beginners Area/Memory access violation after third iteration

The Blitz part of the code seems to run fine, so the error is prob. caused in the .dll.
The code itself doesn't look like something is wrong. I didn't knew you could directly fill a type from a .dll.
It is certainly a strange error, if it occurs only after 3 times. Maybe you are writing to a protected memory section somehow?
I would try to read/fill only the EStructura type, without the Modelo3D and Textura (sub)fields?
If you can't get it to work properly, you could maybe merge all the fields into a string and pass that along, or write a separate function for each field, like GetName, GetX, GetY, GetZ etc.