wave back EA

 

Hey all,

here the idea for my strategy:

Buy:

Open every hour 1 position as long equity is equal or less than account balance. Profit of all positions (with same magic number) will be collect.

Sell:

Same rules!

I attached my 2 EA and need help to merge them to one EA. The challenge is to identify the profit of all open positions with the same magic number to decide if there has to open a position. The code to check profit of all positions with the same magic number and close these positions I have already included. But I need coding help to give a bool data for "profit of positions with magic number 123456 is positive or negative"

Who has the answer?

thanks a lot!

Files:
Reason: