Access voliation read to 0X0FD02000

 

Hello everyone,
I have coded an EA and when I test, it keeps giving me a weired error:

It seems like it is MT4 bug and I cannot do anything about it, I know how to reproduce it and I hope Moderators can help me.

I can share the code, it is a very big EA, but I can send the code for any  Moderator or metatrader staff in private.
Regards.

 
Fatemeh Ameri:

Hello everyone,
I have coded an EA and when I test, it keeps giving me a weired error:

It seems like it is MT4 bug and I cannot do anything about it, I know how to reproduce it and I hope Moderators can help me.

I can share the code, it is a very big EA, but I can send the code for any  Moderator or metatrader staff in private.
Regards.

Can you isolate the code into a simple version, only having the relevant part in it?
 
Dominik Egert #:
Can you isolate the code into a simple version, only having the relevant part in it?

I have to manipulate the code to the great extent if I want to do that, but if it helps I'll do that.

 
Fatemeh Ameri:

Hello everyone,
I have coded an EA and when I test, it keeps giving me a weired error:

It seems like it is MT4 bug and I cannot do anything about it, I know how to reproduce it and I hope Moderators can help me.

I can share the code, it is a very big EA, but I can send the code for any  Moderator or metatrader staff in private.
Regards.

usual suspect areas will be accessing structures or arrays that have not be aligned correctly, or pointers.

 
Paul Anscombe #:

usual suspect areas will be accessing structures and arrays that have not be aligned correctly, or pointers.

I know, but I cannot know whtich  structures or arrays causes the problem and how I should change them, the error gives no useful information.

 
Fatemeh Ameri #:

I know, but I cannot know whtich  structures or arrays causes the problem and how I should change them, the error gives no useful information.

Are you using DLLs? Under normal circumstances, strings cannot leak.
 
Dominik Egert #:
Are you using DLLs? Under normal circumstances, strings cannot leak.
There is no DLL in thr files.
 
Dominik Egert #:
Are you using DLLs? Under normal circumstances, strings cannot leak.

Any other help?

 

Place throughout your EA: Comment(__FILE__," ",__LINE__);

Then you see when and where your EA crashes, as this is the last comment on the chart. And it is easily deleted by find and replace :)

 
Carl Schreiber #:

Place throughout your EA: Comment(__FILE__," ",__LINE__);

Then you see when and where your EA crashes, as this is the last comment on the chart. And it is easily deleted by find and replace :)

I employed this solution, it was very helpful, thank you Sir.Carl Schreiber 

I found out that ObjectsDeleteAll() function has a serious problem and it was the reason to product this error, I hope MQL solves that.

 
Fatemeh Ameri #:

I employed this solution, it was very helpful, thank you Sir.Carl Schreiber 

I found out that ObjectsDeleteAll() function has a serious problem and it was the reason to product this error, I hope MQL solves that.

So now you have been helped. You should state the solution and if you think there is a bug you should provide the information for that as well
Otherwise why should people help you or anyone else in the future
Reason: