Manual order and EA closing - page 2

 
deVries:
That line takes possible actions ONLY for the other trades, manually opened ones, because we consider there are some Magic Number for the current EA with number >0, and the next
else if
statement is proceeding to the assigned , or the rest opened trades with magic number different than the previous checking. But if there are other trades with fixed Magic Number from other EA's than that statement should be changed with adding exception
..|| OrderMagicNumber()!=FixedRecognitionNumber ..
than also can be range of number comparison also. This is just basic form, IT needs to be adjusted by individual needs.
 
rfb:
That line takes possible actions ONLY for the other trades, manually opened ones, because we consider there are some Magic Number for the current EA with number >0, and the nextstatement is proceeding to the assigned , or the rest opened trades with magic number different than the previous checking. But if there are other trades with fixed Magic Number from other EA's than that statement should be changed with adding exceptionthan also can be range of number comparison also. This is just basic form, IT needs to be adjusted by individual needs.


What difference has your line

  if( OrderMagicNumber()!=ThisEaMagicNumber || OrderMagicNumber()<1 )

 with 

  if( OrderMagicNumber()!=ThisEaMagicNumber )

 .....

but i don't think that the OP wanted trades made by other EA's same Symbol()  other strategy to be managed 

I think he wanted still the EA was managing of its own and manual placed trades.....

and if so that won't happen with your line .... inside the way you did 

 

His last call in text was:

" @12BPRO2 Answering RaptorUK -  If you filter correctly by Symbol and/or Magic Number then no, it won't.

If that's the CASE what if I change the magicnumber = 0, would it do the trick.

or I have change the following command line....

magicNumber to OrderTicket..."

A: Based on that: There are few solutions that he might want to do, I considered he KNOWS HOW, that is if he take last opened trade TICKET and than assign next number... or simply take the first MagicNumber to the first trade to be 1 i.e. any > 0

But on second thought I figure that you ask that that statement will prevent managing trades from the existing editing-EA , but the line 

if( OrderMagicNumber()!=ThisEaMagicNumber || OrderMagicNumber()<1 ) {the code here }
will exclude own trades, and "else continue;" within brackets will skip further checking because it is recognized as other trade, for that ticket number, and the next ticket if does not apply to that conditions from the previous up statement than it's considered own trade from EA and applies the next 
else if(...)
and there is choice for next if(checking) for other conditions for the current EA trades. I hope I am explaining without any or empty arrogance.
 

I am loss Guys............

I will give it a try... on the first suggestion ReptorUK and DeVries....

and see what will happen...

The rest is to It's too complicated for me to understand (absorb)....

Thanks a lot, you guys have been very helpful...

Best Regards...........

 

Hi All,

Wow it's a bit more complicated than what I think...

I will try the first and second suggestion but the rest is to hard for me to understand....

Thanks for the time and your opinion here, it is highly appreciated...

Best regards.........

 

Hi All....

I just want to update all of all that commented in this topic.....

Thanks a lot now my MANUAL and AUTO trade could be closed by my EA........

I really appreciated all of you for taking your time and  initiative to HELP others

Best Regards......

AZR

 
AZRUL AZMI:

Hi All....

I just want to update all of all that commented in this topic.....

Thanks a lot now my MANUAL and AUTO trade could be closed by my EA........

I really appreciated all of you for taking your time and  initiative to HELP others

Best Regards......

AZR

Can i have it?

 
Indranx Avataram:

Can i have it?

Have what?

Reason: