How to test to see if my EA magic number is working?

 
I have an EA a programmer said the magic number isn't being recognized. How do I see if the magic number is being recognized by mt4 is there a way to test and validate this without being programmer? 
 

This is strange question.

Magic number is not mandatory in the order, but if there is a magic in the order, you can read it from MQL.

Magic number can be written to the order only at the moment when the order is opened. It can't be changed after that.  

 

Attached is a script that will list order tickets and corresponding magic numbers. List will be visible at the Experts tab. 

Copy attached file to the scripts folder. 

Files:
 
drazen64:

This is strange question.

Magic number is not mandatory in the order, but if there is a magic in the order, you can read it from MQL.

Magic number can be written to the order only at the moment when the order is opened. It can't be changed after that.  

 

Attached is a script that will list order tickets and corresponding magic numbers. List will be visible at the Experts tab. 

Copy attached file to the scripts folder. 

Thank you so much I'll have a look at the script. Do you think the magic number issue might be causing multiple EA's opening at the same time even though they have different logic? In those EA's I have different magic numbers for each 
 

Magic number is just some random value you can attach to you order. It is usually used as means of order identification. For example - you can read that number from the order and then decide if that order should be included in some decision.

You must ask your developer what exactly he means  with "magic number isn't being recognized". If order has magic number, you can read it. If order does not have magic number - you can't read it. 

Without code it is impossible to tell what is happening. 

 
Dave90210:
Thank you so much I'll have a look at the script. Do you think the magic number issue might be causing multiple EA's opening at the same time even though they have different logic? In those EA's I have different magic numbers for each 
G'day Dave

Were the EA's all created by the same coder? If so, he may have accidentally hard coded the same magic into every EA rather than using the input variable. As drazen said above, without seeing the code the best we can do is guess ;)

Cheers
 
Filter:
G'day Dave

Were the EA's all created by the same coder? If so, he may have accidentally hard coded the same magic into every EA rather than using the input variable. As drazen said above, without seeing the code the best we can do is guess ;)

Cheers
I sent you a PM with the code. Originally only one guy worked on it and later someone came in to make some changes and thats when he said he say an error with the magic number 
 

After a quick look, it seems that there shouldn't be magic number problems in this EA.

Only thing I discovered is that EA does not check magic number when it is closing order.

So, if you have same type orders on the same currency pair, this EA will close all of them, no matter which magic number they have.

This means that EA can close orders that it did not open. 

 

Detailed test requires time and you should provide detailed description of problems - what is happening and what you expected to happen. 

 
I can confirm the same as drazen, it will close all orders on that symbol. Sent you a PM too :)
 
Thank you all. I have had the same question about magic numbers.  This helps!