Can anyone create the code for the following details:
Forex Tick Stalker
I need an EA that will do the following:
Place two orders (1 buy and 1 sell) simultaneously at the starting price of each BAR (minute). With a selected stoploss, one of the two orders will close and hopefully the other will continue at a profit. This remaining order will try to get to take profit target.
This order will be closed 15 seconds (adjustable at Input Parameter) before the BAR (minute) ends.
The cycle begins again on the next BAR (minute).
The following are adjustable Input Parameters:
Header1="Tick Stalker"
TimeOnHour=0.0
TimeOffHour=23.0
RiskPercentage=1.0
MaxOrders=1
MaxLots=50
MaxSpread=6
StopLoss=0.0
TrailingStop=2.0
TakeProfit=10.0
1MCloseAfterSeconds= 40 seconds (this parameter can be adjustable between 40 seconds to 55 seconds
5MCloseAfterSeconds= 295 seconds (4minutes 55 second)
GMT=1
MagicNumber=13579
DailyProfitTarget=500.0 (this parameter is adjusted in increments of 500.00)
Details:
- The EA should be able to work on all major currencies on timeframe of 1M and 5M.
- On the chart BAR a blue arrow shows where orders were placed and a green arrow shows where the order was closed with profit. If it closed without profit the arrow will be red.
- Order should be closed before the ending of the BAR (minute).
- If next BAR (minute) appears and the order did not close it should close before the new two orders (buy and sell) are open.
- Once DailyProfitTarget is reached the EA will stop trading until the next TimeOnHour.
- The EA should be able to trade with two different currencies at the same time on their own with different Magic Numbers. (Ej. Each would work with their own DailyProfitTarget)
Thanks To All