Spécifications
In my EA I want to changes:
2. I have already an EA which is opening after first installation (under Strategie 1) a buy and sell order and after one of these orders has been closed, ea is placing a pending order with an entry trigger. Note EA does only place at the beginning an buy and sell order. If buy is closed EA open an buy in Pending with an trigger. If sell is closed EA open an sell in trigger. This goes so on.
If this pending order with trigger is executed in the market, EA is opening
again and pending after the order in market is closed and so on.
Do not change anything of Strategie of Strategie 1 just ad the function to Strategie 1
What do I want now?
Moneymanegment for all orders which are active in Market stays as it does
right now. Do not chang anything
I want if EA has placed the basis order (basis orders are the orders which are
activ in the market – the buy and sell order) or when ea is new on chart and if
there is already a basis order (basis order is buy and sell order) are in the
Market - EA should place direct following order (which EA would place after
Basis order is closed) place as pending direct and not when first order is
closed.
So in Terminal are than:
In Market – the buy and sell order
And in Pending status the pending buy and pending sell order – execution Limit Xpips away of TP of basis order in Market. Pips right now as pending open after Basis is closed.
So after Basis is closed at market, SL or TP - from this
closing price will be again calculated the opening price of Pending
order.
Distance of pending order
is: actual TP of first order plus input double PendingOrderPips=100; - So not
TP of first order is changing - so TP of pending has to be updated.
Lots- same as first order.
And after closing of Bais order in Market
ist closed - Market, TP or SL - EA should chek execution Price of
Pending order. This is than Closing price of Bais order. plus input double PendingOrderPips=100; - So not
TP of first order is changing - so TP of pending has to be updated.
So Note - every basis (basis is orders activ in terminal) order in Terminal
does have following orders in Pending Status:
The Trigger of the pending orders should be active when basis order is
closed (in actual strategy 1 and 2 pendings are alredy triggered). Trigger
should work as he does right now.
Again: So if there is a basis buy or, and a sell order in the market. EA
should place for each basis direct the next pending order and should not wait till
basis order is closed.
Trigger of the pending order should be active if basis order is closed.
For the Pending orders I want to have one more execution option:
First Execution Option does alredy exist – it is the trigger in Market.
Second is not trigger Order executed as Xpips away or Xpips better. Xpips away is alredy there this is begin of trigger – I Just want to definite Xpips better. 60 Pips means after basis is closed Pending will be again in Market xpips away or xpips better.
Explanation:
EA opens the buy and sell order and also pending status the next buy and sell order as pending.
If basis buy or sell order is closed – Pending order will be active and executed as trigger or xpips better.
That’s it
Second change. EA should know his orders under global variables to ovoid double opening.
2. After restarting Terminal or new installation EA forgot all ticket and try work with new. EA should check to have only 2 open orders in pending and 2 Orders open in Market – each from the can only be a buy and an sell.
EA should remember his oders and tickets. So after restarting plattform, problem with Internet EA should knows status of before.
If EA does not have 2 Orders in Market and 2 Orders in Pending – EA should open 2 Orders Market.
If EA does not have 2 Orders in Market but 2 Orders in Pending – EA should do nothing.
EA does never have 3 or 4 Orders in Market…. Never only 2 and this can only be a buy and a sell order.
Can be a text file which save all ticket numbers there and update it repeatedly. so when restart the system or any other disconnection of system can check it's text first to remember them.