EA stop working if magic number is changed to zero on USOIL

 

Hi all 

I developed an EA that works perfectly on every symbols except USOIL.

My issues are

1)  EA does not work if magic number is changed to "Zero".

2)  EA works if keep default magic number "5258", but does not recognizing manually opened trades. This is very crucial as i open many trades manually


I am not a n expert in programming . if anyone can help me that will be grate relief


Thanks

 

Magic number = 0 will be the same of a manual trade.

No reason for EA to not allow to set it to 0, the only possible reason is that EA have a specific filter to not allowing it to be set to 0.

 
Fabio Cavalloni #:

Magic number = 0 will be the same of a manual trade.

No reason for EA to not allow to set it to 0, the only possible reason is that EA have a specific filter to not allowing it to be set to 0.

Hi Fabio


The EA works fine for other symbols. i am facing this issue only on USOIL

 
Lijo Antony #:

Hi Fabio


The EA works fine for other symbols. i am facing this issue only on USOIL

Then fix your code. If you need coding help, show your code.
 
Lijo Antony:

Hi all 

I developed an EA that works perfectly on every symbols except USOIL.

My issues are

1)  EA does not work if magic number is changed to "Zero".

2)  EA works if keep default magic number "5258", but does not recognizing manually opened trades. This is very crucial as i open many trades manually


I am not a n expert in programming . if anyone can help me that will be grate relief


Thanks

Maybe you have it on for another pair, also with magic number=0. Have you tried to test it only with USOIL, no other pair simultaneously.

But Magic Number is how your EA will differentiate the pairs.

If you have to put the trades manually, then use a script where you can put a magic number... this way your new trade will have a magic number and your EA will handle it.

 
Daniel Cioca #:

Maybe you have it on for another pair, also with magic number=0. Have you tried to test it only with USOIL, no other pair simultaneously.

But Magic Number is how your EA will differentiate the pairs.

If you have to put the trades manually, then use a script where you can put a magic number... this way your new trade will have a magic number and your EA will handle it.

Your message is based only on your personal experience and not on absolute truth.

Personally if I want my EA to handle my manual trades I will set magic number to 0.

I use a magic number for identifying an EA, and will be the same for all symbols to which I used that EA.

But this is related to how an EA is coded, we cannot know how it will work without seeing the code.

 
Fabio Cavalloni #:

Your message is based only on your personal experience and not on absolute truth.

Personally if I want my EA to handle my manual trades I will set magic number to 0.

I use a magic number for identifying an EA, and will be the same for all symbols to which I used that EA.

But this is related to how an EA is coded, we cannot know how it will work without seeing the code.

But you don’t know his code either… how come you are holding the absolute truth… you even say that you personally set the MA to 0 for some reason… you don’t know his code so you shared from your personal experience … as did I … off course I share my personal thoughts … if it helps him fine… if not… also fine… maybe your idea is better and it will help him… relax mate… peace 
 
Fabio Cavalloni #:

Your message is based only on your personal experience and not on absolute truth.

Personally if I want my EA to handle my manual trades I will set magic number to 0.

I use a magic number for identifying an EA, and will be the same for all symbols to which I used that EA.

But this is related to how an EA is coded, we cannot know how it will work without seeing the code.

Also… holder of the absolute truth… how will Your EA handle two opened trades on same pair on M15 and M30…. you have to put 1000 filters for your trades … instead of using one unic number 
 
Daniel Cioca #:
Also… holder of the absolute truth… how will Your EA handle two opened trades on same pair on M15 and M30…. you have to put 1000 filters for your trades … instead of using one unic number 

I never said I have the absolute truth, I just gave an example that me personally i'm doing different of what you said. I'm not saying that my way is better but that it's different.

You shouldn't feel attacked by me, I'm only talking about the fact that without the code we cannot make assumptions. Calm down.

In addition to this, depending on cases (for example a multi strategy EA) I use different magic numbers too, but not for identify a symbol (that is already identified by itself name) but mostly for identifying an EA (or a sub-strategy of an EA).