magic number - page 2

 
kinjal parekh:

how will it derail my expert? its a geniun quistion


Well it uses the magic number to track your trades so it's not so hard to see how that messing with it would completely and utterly derail your expert.

 
Marco vd Heijden:


Well it uses the magic number to track your trades so it's not so hard to see how that messing with it would completely and utterly derail your expert.

i see now,

as my ea opens order on bar close below sma , now its opening order on everybar close below sma as it send new magic number with every trade. 

 
  1. Why did you post your MT4 question in the Root / MT5 EA section instead of the MQL4 section, (bottom of the Root page?)
              General rules and best pratices of the Forum. - General - MQL5 programming forum
    Next time post in the correct place. The moderators will likely move this thread there soon.

  2. You only need one MN/EA/TF. Why do you think you need one per trade? Using OrdersTotal/OrdersHistoryTotal (MT4) or PositionsTotal (MT5), directly and/or no Magic number filtering on your OrderSelect/Position select loop means your code is incompatible with every EA (including itself on other charts and manual trading.)
              Symbol Doesn't equal Ordersymbol when another currency is added to another seperate chart . - MQL4 programming forum
              MagicNumber: "Magic" Identifier of the Order - MQL4 Articles
 
William Roeder:
  1. Why did you post your MT4 question in the Root / MT5 EA section instead of the MQL4 section, (bottom of the Root page?) 

Moved to the correct sub-forum