How to modify magicnumber ?

 

Hello

i want to make EA that depends on magic number for closing a group of orders but, i want the first order to take its ticket as magic number and that order will be the master of 3 orders and the 3 orders will take the first magic number of the first order.

Example:

int Tic
Tic=OrderSend(Symbol(),OP_BUY,LotSize,Ask,3,Ask-SL*Point*M,Ask+TP*Point*M,"MyEA",Tic,0,Green);

But the problem the magic number will not be taken to the ordersend. So is there any method to make ordermodify to modify new magic number for that order ?

i hope my question is clear .

 
fx2013:

Hello

i want to make EA that depends on magic number for closing a group of orders but, i want the first order to take its ticket as magic number and that order will be the master of 3 orders and the 3 orders will take the first magic number of the first order.

Example:

But the problem the magic number will not be taken to the ordersend. So is there any method to make ordermodify to modify new magic number for that order ?

i hope my question is clear .



how can you get a ticketnumber of a trade before a trade is opend so you can use it as MagicNumber ??

you can't modify magicnumber

 
The MN is set by the OrderSend. RTFM, which parameter in the OrderModify is the magic number?
 
fx2013:

Hello

i want to make EA that depends on magic number for closing a group of orders but, i want the first order to take its ticket as magic number and that order will be the master of 3 orders and the 3 orders will take the first magic number of the first order.

Example:

But the problem the magic number will not be taken to the ordersend. So is there any method to make ordermodify to modify new magic number for that order ?

i hope my question is clear .



ordermagicnumber is not modify.